Skip to content

Commit da62def

Browse files
committed
fix(component): check instance is null in capture
1 parent 70734d7 commit da62def

File tree

1 file changed

+2
-0
lines changed
  • packages/app-backend-vue3/src/components

1 file changed

+2
-0
lines changed

packages/app-backend-vue3/src/components/tree.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -130,6 +130,8 @@ export class ComponentWalker {
130130
* @return {Object}
131131
*/
132132
private async capture (instance: any, list: any[], depth: number): Promise<ComponentTreeNode> {
133+
if (!instance) return null
134+
133135
const id = this.captureId(instance)
134136

135137
const name = getInstanceName(instance)

0 commit comments

Comments
 (0)