Skip to content

Commit 40a0131

Browse files
committed
🐞 fix: prevent multi registers
1 parent 0f4abc7 commit 40a0131

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

lib/runtimeFiltersPlugin/runtimeFiltersPlugin.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,10 @@ export class RuntimeFiltersPlugin<
5555
}
5656
}
5757

58+
let registered = false;
5859
export function registerRuntimeFiltersPlugin() {
59-
SchemaBuilder.registerPlugin(pluginName, RuntimeFiltersPlugin);
60+
if (!registered) {
61+
SchemaBuilder.registerPlugin(pluginName, RuntimeFiltersPlugin);
62+
registered = true;
63+
}
6064
}

0 commit comments

Comments
 (0)