@cspell/strong-weak-map
Advanced tools
Comparing version 8.2.3 to 8.2.4
@@ -113,3 +113,11 @@ export class StrongWeakMap { | ||
cleanKeys() { | ||
[...this]; | ||
const keysToDel = []; | ||
for (const [key, ref] of this.map.entries()) { | ||
if (!ref.deref()) { | ||
keysToDel.push(key); | ||
} | ||
} | ||
for (const key of keysToDel) { | ||
this.map.delete(key); | ||
} | ||
return this; | ||
@@ -116,0 +124,0 @@ } |
@@ -6,3 +6,3 @@ { | ||
}, | ||
"version": "8.2.3", | ||
"version": "8.2.4", | ||
"description": "A Map with weakly referenced values.", | ||
@@ -58,3 +58,3 @@ "keywords": [ | ||
}, | ||
"gitHead": "e3098b21e0a199d61226f8ff4989d48b385eddfa" | ||
"gitHead": "d3c5ff685b3aa2bf984f557d81380f2c994547e0" | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
10629
186