Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/types/complex-types/map.ts
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,6 @@ export class MapType<S, T> extends ComplexType<{[key: string]: S}, IExtendedObse
fail(`A map of objects containing an identifier should always store the object under their own identifier. Trying to store key '${key}', but expected: '${item[identifierAttr]}'`)
// if snapshot[key] is non-primitive, and this.get(key) has a Node, update it, instead of replace
if (key in currentKeys && !isPrimitive(item)) {
currentKeys[key] = true
maybeMST(
target.get(key),
propertyNode => {
Expand All @@ -172,6 +171,7 @@ export class MapType<S, T> extends ComplexType<{[key: string]: S}, IExtendedObse
} else {
target.set(key, item)
}
currentKeys[key] = true
})
Object.keys(currentKeys).forEach(key => {
if (currentKeys[key] === false)
Expand Down