Use `WeakSet` for dependency manager forms
authorMatthias Schmidt <gravatronics@live.com>
Tue, 15 Dec 2020 17:40:44 +0000 (18:40 +0100)
committerGitHub <noreply@github.com>
Tue, 15 Dec 2020 17:40:44 +0000 (18:40 +0100)
Co-authored-by: Tim Düsterhus <duesterhus@woltlab.com>
wcfsetup/install/files/ts/WoltLabSuite/Core/Form/Builder/Field/Dependency/Manager.ts

index 6933eee9ccb7998a6f4b387d49aa4cd049e83923..521957365a8a39e6f1cf55c3cf2300ba7f287444 100644 (file)
@@ -18,7 +18,7 @@ type PropertiesMap = Map<string, string>;
 
 const _dependencyHiddenNodes = new Set<HTMLElement>();
 const _fields = new Map<string, HTMLElement>();
-const _forms = new Set<HTMLElement>();
+const _forms = new WeakSet<HTMLElement>();
 const _nodeDependencies = new Map<string, FormBuilderFormFieldDependency[]>();
 const _validatedFieldProperties = new WeakMap<HTMLElement, PropertiesMap>();