@poe-platform/safe-js 0.1.140 → 0.1.142

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.
@@ -27,7 +27,7 @@ import {
27
27
  validateMigrationSemantics,
28
28
  validateSnapshotData,
29
29
  validateSnapshotMigration
30
- } from "./chunk-FYPACPSN.js";
30
+ } from "./chunk-YKISHTWT.js";
31
31
 
32
32
  // packages/safe-js/src/migrate.ts
33
33
  import { createHash } from "node:crypto";
@@ -8249,4 +8249,4 @@ export {
8249
8249
  parseMcpConfig,
8250
8250
  makeMcpModule
8251
8251
  };
8252
- //# sourceMappingURL=chunk-VCCBGXLZ.js.map
8252
+ //# sourceMappingURL=chunk-KZ6SIA7S.js.map
@@ -4751,7 +4751,10 @@ var Parser = class {
4751
4751
  return (propertyToken.type === "identifier" || propertyToken.type === "keyword" || propertyToken.type === "numeric" || propertyToken.type === "string") && this.peekToken(2).type === "punctuator" && this.peekToken(2).value === "(";
4752
4752
  }
4753
4753
  parseObjectMethod(asyncToken, methodStart) {
4754
- const { params, body } = this.parseFunctionParts(false, ordinaryFunctionContext);
4754
+ const { params, body } = this.parseFunctionParts(false, {
4755
+ ...ordinaryFunctionContext,
4756
+ superProperty: true
4757
+ });
4755
4758
  return this.withFunctionSource({
4756
4759
  type: "FunctionExpression",
4757
4760
  async: asyncToken !== void 0,
@@ -28960,7 +28963,11 @@ async function evaluateObjectExpression(node, context) {
28960
28963
  const releaseKey = retainValues(context.budget, () => [key.value]);
28961
28964
  let value;
28962
28965
  try {
28963
- value = await evaluateNode(property.value, { ...context, inferredName: String(key.value) });
28966
+ value = await evaluateNode(property.value, {
28967
+ ...context,
28968
+ inferredName: String(key.value),
28969
+ ...property.value.type === "FunctionExpression" && property.value.method === true ? { functionEnvironment: { homeObject: object } } : {}
28970
+ });
28964
28971
  } finally {
28965
28972
  releaseKey();
28966
28973
  }
@@ -28985,7 +28992,7 @@ async function evaluateObjectExpression(node, context) {
28985
28992
  }
28986
28993
  }
28987
28994
  function isObjectPrototypeSetterProperty(property, key) {
28988
- return !property.computed && !property.shorthand && key === "__proto__";
28995
+ return !property.computed && !property.shorthand && key === "__proto__" && !(property.value.type === "FunctionExpression" && property.value.method === true);
28989
28996
  }
28990
28997
  async function evaluateTemplateLiteral(node, context) {
28991
28998
  let value = context.budget.allocateString(node.quasis[0]?.value.cooked ?? "");
@@ -31570,7 +31577,12 @@ async function evaluateFunctionExpression(node, context, evaluateNode2) {
31570
31577
  return {
31571
31578
  kind: "normal",
31572
31579
  hasValue: true,
31573
- value: createInterpretedClosure(node, context, evaluateNode2)
31580
+ value: createInterpretedClosure(
31581
+ node,
31582
+ context,
31583
+ evaluateNode2,
31584
+ node.method === true ? context.functionEnvironment?.homeObject : void 0
31585
+ )
31574
31586
  };
31575
31587
  }
31576
31588
  const wrapperScope = context.scope.child();
@@ -35499,4 +35511,4 @@ export {
35499
35511
  FileSnapshotBackend,
35500
35512
  run
35501
35513
  };
35502
- //# sourceMappingURL=chunk-FYPACPSN.js.map
35514
+ //# sourceMappingURL=chunk-YKISHTWT.js.map