Skip to content

Commit

Permalink
fix(devtools): fix serialize function
Browse files Browse the repository at this point in the history
  • Loading branch information
janryWang committed Jan 31, 2021
1 parent c84a4b7 commit 36aef5b
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
1 change: 1 addition & 0 deletions packages/devtools/src/extension/backend.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ const serializeObject = (obj: any) => {
for (let key in obj) {
result[key] = serialize(obj[key])
}
seens.set(obj, false)
return result
}
}
Expand Down
2 changes: 1 addition & 1 deletion packages/devtools/src/extension/manifest.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"version": "0.1.12",
"version": "0.1.13",
"name": "Formily DevTools",
"short_name": "Formily DevTools",
"description": "Formily DevTools for debugging application's state changes.",
Expand Down
4 changes: 3 additions & 1 deletion packages/json-schema/src/complier.ts
Original file line number Diff line number Diff line change
Expand Up @@ -70,14 +70,16 @@ export const complie = <Source = any, Scope = any>(
return source
}
seenObjects.set(source, true)
return reduce(
const results = reduce(
source,
(buf, value, key) => {
buf[key] = complie(value)
return buf
},
{}
)
seenObjects.set(source, false)
return results
}
return source
}
Expand Down

0 comments on commit 36aef5b

Please sign in to comment.