Skip to content
Myr

fix: Fixed #477, Immer crashes without an Object.assign polyfill

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Michel Weststrate · committed by Michel Weststrate · parent d3be40e · Browse files · 2 files+9 added−3 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

2 files+9 added−3 removed

  • tests:+5 added−0 removed
  • other:+4 added−3 removed

2 files+9 added−3 removed

modified:__tests__/polyfills.js+5 added
modified:src/common.js+4 added-3 removed
62 unmodified lines
6364export const assign =65 Object.assign ||66 ((target, ...overrides) => {67 overrides.forEach(override =>68 Object.keys(override).forEach(key => (target[key] = override[key]))69 )67 overrides.forEach(override => {68 if (typeof override === "object" && override !== null)69 Object.keys(override).forEach(key => (target[key] = override[key]))70 })71 return target72 })7374export const ownKeys =
173 unmodified lines