@poe-platform/safe-js 0.1.267 → 0.1.269
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.
- package/dist/safe-js/chunks/{chunk-GF6I2VQR.js → chunk-VIBISLKQ.js} +19 -8
- package/dist/safe-js/chunks/chunk-VIBISLKQ.js.map +7 -0
- package/dist/safe-js/chunks/{chunk-MEDRKFEW.js → chunk-X6PGF53P.js} +2 -2
- package/dist/safe-js/cli.js +2 -2
- package/dist/safe-js/core.js +1 -1
- package/dist/safe-js/index.js +2 -2
- package/package.json +2 -2
- package/dist/safe-js/chunks/chunk-GF6I2VQR.js.map +0 -7
- /package/dist/safe-js/chunks/{chunk-MEDRKFEW.js.map → chunk-X6PGF53P.js.map} +0 -0
|
@@ -11737,10 +11737,14 @@ function createPromiseGlobals(options) {
|
|
|
11737
11737
|
if (typeof constructor !== "object" || constructor === null) {
|
|
11738
11738
|
throw new TypeError("Promise.resolve requires an object receiver.");
|
|
11739
11739
|
}
|
|
11740
|
-
|
|
11741
|
-
return value;
|
|
11742
|
-
|
|
11743
|
-
|
|
11740
|
+
const finish = (actualConstructor2) => {
|
|
11741
|
+
if (isSandboxPromise(value) && actualConstructor2 === constructor) return value;
|
|
11742
|
+
return isSandboxPromiseConstructor(constructor) ? createSandboxPromise(resolveSandboxValue(value, { budget: options.budget })) : settleConstructedPromise(constructor, value, "fulfilled", options.budget, context);
|
|
11743
|
+
};
|
|
11744
|
+
if (!isSandboxPromise(value)) return finish(void 0);
|
|
11745
|
+
const descriptor = getSandboxPropertyDescriptor(value, "constructor", options.budget);
|
|
11746
|
+
const actualConstructor = descriptor === void 0 ? getPromiseMember("constructor", options.budget) : readPropertyDescriptor(descriptor, value, context, true);
|
|
11747
|
+
return actualConstructor instanceof Promise ? actualConstructor.then(finish) : finish(actualConstructor);
|
|
11744
11748
|
},
|
|
11745
11749
|
name: "resolve"
|
|
11746
11750
|
}),
|
|
@@ -12106,7 +12110,12 @@ function resolveSandboxValueNow(value, options) {
|
|
|
12106
12110
|
(reason) => Promise.reject(budgetIfNeeded(reason, options.budget))
|
|
12107
12111
|
);
|
|
12108
12112
|
}
|
|
12109
|
-
if (
|
|
12113
|
+
if (isSelfResolution(value, options.self)) {
|
|
12114
|
+
return Promise.reject(
|
|
12115
|
+
options.budget === void 0 ? new TypeError("Promise cannot resolve to itself.") : createSubsetErrorValue("TypeError", "Promise cannot resolve to itself.", [], options.budget)
|
|
12116
|
+
);
|
|
12117
|
+
}
|
|
12118
|
+
if (isSandboxPromise(value) && getSandboxPropertyDescriptor(value, "then", options.budget) === void 0) {
|
|
12110
12119
|
if (options.budget !== void 0) {
|
|
12111
12120
|
return resolvePromiseResult(value, options.budget, options.self);
|
|
12112
12121
|
}
|
|
@@ -12260,7 +12269,9 @@ function resolvePromiseResult(result, budget, self) {
|
|
|
12260
12269
|
createSubsetErrorValue("TypeError", "Promise cannot resolve to itself.", [], budget)
|
|
12261
12270
|
);
|
|
12262
12271
|
}
|
|
12263
|
-
if (!isSandboxPromise(result)
|
|
12272
|
+
if (!isSandboxPromise(result) || getSandboxPropertyDescriptor(result, "then", budget) !== void 0) {
|
|
12273
|
+
return resolveSandboxValue(result, { budget, self });
|
|
12274
|
+
}
|
|
12264
12275
|
const then = getPromiseMember("then", budget);
|
|
12265
12276
|
if (!isSandboxClosure(then)) return Promise.resolve(result);
|
|
12266
12277
|
return new Promise((resolve, reject) => {
|
|
@@ -12324,7 +12335,7 @@ function requiresPromiseResolution(value, budget) {
|
|
|
12324
12335
|
return descriptor !== void 0 && (!("value" in descriptor) || isSandboxClosure(descriptor.value));
|
|
12325
12336
|
}
|
|
12326
12337
|
function getThenable(value, budget) {
|
|
12327
|
-
if (typeof value !== "object" || value === null
|
|
12338
|
+
if (typeof value !== "object" || value === null) {
|
|
12328
12339
|
return void 0;
|
|
12329
12340
|
}
|
|
12330
12341
|
const descriptor = getSandboxPropertyDescriptor(value, "then", budget);
|
|
@@ -40089,4 +40100,4 @@ export {
|
|
|
40089
40100
|
FileSnapshotBackend,
|
|
40090
40101
|
run
|
|
40091
40102
|
};
|
|
40092
|
-
//# sourceMappingURL=chunk-
|
|
40103
|
+
//# sourceMappingURL=chunk-VIBISLKQ.js.map
|