@poe-platform/safe-js 0.1.396 → 0.1.397

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -27027,10 +27027,10 @@ var registries = /* @__PURE__ */ new WeakMap();
27027
27027
  function createSymbolGlobal(budget) {
27028
27028
  let registry = registries.get(budget);
27029
27029
  if (registry === void 0) {
27030
- registry = /* @__PURE__ */ new Map();
27030
+ registry = createSandboxMap();
27031
27031
  registries.set(budget, registry);
27032
27032
  }
27033
- const entries = registry;
27033
+ const entries = registry.entries;
27034
27034
  const prototype = /* @__PURE__ */ Object.create(null);
27035
27035
  const valueOf = createSandboxClosure({
27036
27036
  sandbox: true,
@@ -27082,7 +27082,7 @@ function createSymbolGlobal(budget) {
27082
27082
  sandbox: true,
27083
27083
  name: "Symbol",
27084
27084
  length: 0,
27085
- retainedValues: () => [...entries.keys(), ...entries.values()],
27085
+ retainedValues: () => [registry],
27086
27086
  call: async ([description], context) => Symbol(
27087
27087
  description === void 0 ? void 0 : await sandboxString(description, budget, context)
27088
27088
  )
@@ -27094,6 +27094,7 @@ function createSymbolGlobal(budget) {
27094
27094
  sandbox: true,
27095
27095
  name: "for",
27096
27096
  length: 1,
27097
+ retainedValues: () => [registry],
27097
27098
  call: async ([key], context) => {
27098
27099
  const text = await sandboxString(key, budget, context);
27099
27100
  let value = entries.get(text);
@@ -27108,6 +27109,7 @@ function createSymbolGlobal(budget) {
27108
27109
  sandbox: true,
27109
27110
  name: "keyFor",
27110
27111
  length: 1,
27112
+ retainedValues: () => [registry],
27111
27113
  call: ([value]) => {
27112
27114
  if (typeof value !== "symbol") throw new TypeError("Symbol.keyFor requires a symbol.");
27113
27115
  for (const [key, registered] of entries) if (registered === value) return key;
@@ -45041,4 +45043,4 @@ export {
45041
45043
  FileSnapshotBackend,
45042
45044
  run
45043
45045
  };
45044
- //# sourceMappingURL=chunk-BVKIA2LQ.js.map
45046
+ //# sourceMappingURL=chunk-6HQSVAXP.js.map