mirror of
https://github.com/cudr/slate-collaborative.git
synced 2024-10-27 20:34:06 +00:00
fix: map error
This commit is contained in:
parent
c59e5239e4
commit
7f2bd39402
@ -57,6 +57,11 @@ const opRemove = (op: Automerge.Diff, [map, ops]: any) => {
|
||||
try {
|
||||
const { index, path, obj, type } = op
|
||||
|
||||
// early return if no map obj available
|
||||
if (!map) {
|
||||
return [map, ops]
|
||||
}
|
||||
|
||||
if (
|
||||
map.hasOwnProperty(obj) &&
|
||||
typeof map[obj] !== 'string' &&
|
||||
|
Loading…
Reference in New Issue
Block a user