diff --git a/packages/amis-core/src/SchemaRenderer.tsx b/packages/amis-core/src/SchemaRenderer.tsx index 150507216..25bdfcf80 100644 --- a/packages/amis-core/src/SchemaRenderer.tsx +++ b/packages/amis-core/src/SchemaRenderer.tsx @@ -238,7 +238,8 @@ export class SchemaRenderer extends React.Component { if (ref) { // 这里无法区分监听的是不是广播,所以又bind一下,主要是为了绑广播 - this.unbindEvent = bindEvent(this.ref); + this.unbindEvent?.(); + this.unbindEvent = bindEvent(ref); } this.cRef = ref; }