@agoric/eventual-send
Advanced tools
Comparing version 0.14.1-dev-ac23367.0 to 0.14.1-dev-ae98f61.0
{ | ||
"name": "@agoric/eventual-send", | ||
"version": "0.14.1-dev-ac23367.0+ac23367", | ||
"version": "0.14.1-dev-ae98f61.0+ae98f61", | ||
"description": "Extend a Promise class to implement the eventual-send API", | ||
@@ -13,5 +13,4 @@ "type": "module", | ||
"build": "exit 0", | ||
"lint-fix": "yarn lint:eslint --fix && yarn lint:types", | ||
"lint-check": "yarn lint", | ||
"lint": "yarn lint:types && yarn lint:eslint", | ||
"lint-fix": "yarn lint:eslint --fix", | ||
"lint": "run-s --continue-on-error lint:*", | ||
"lint:types": "tsc -p jsconfig.json", | ||
@@ -31,5 +30,4 @@ "lint:eslint": "eslint '**/*.js'" | ||
"devDependencies": { | ||
"@agoric/assert": "0.3.16-dev-ac23367.0+ac23367", | ||
"@agoric/lockdown": "0.1.2-dev-ac23367.0+ac23367", | ||
"@endo/ses-ava": "^0.2.13", | ||
"@endo/lockdown": "^0.1.5", | ||
"@endo/ses-ava": "^0.2.17", | ||
"ava": "^3.12.1", | ||
@@ -52,6 +50,2 @@ "c8": "^7.7.2" | ||
}, | ||
"prettier": { | ||
"trailingComma": "all", | ||
"singleQuote": true | ||
}, | ||
"publishConfig": { | ||
@@ -66,3 +60,3 @@ "access": "public" | ||
}, | ||
"gitHead": "ac23367148f7b5d5a19cf0aef312251b036acb46" | ||
"gitHead": "ae98f610cd8b8f1118aa9af92256aef738edffac" | ||
} |
10
src/E.js
// @ts-check | ||
import { trackTurns } from './track-turns.js'; | ||
// eslint-disable-next-line spaced-comment | ||
/// <reference path="index.d.ts" /> | ||
@@ -39,6 +38,7 @@ | ||
// #95 for details. | ||
return (...args) => harden(HandledPromise.applyMethod(x, p, args)); | ||
return (...args) => | ||
harden(HandledPromise.applyMethod(x, p, harden(args))); | ||
}, | ||
apply(_target, _thisArg, argArray = []) { | ||
return harden(HandledPromise.applyFunction(x, argArray)); | ||
return harden(HandledPromise.applyFunction(x, harden(argArray))); | ||
}, | ||
@@ -65,3 +65,3 @@ has(_target, _p) { | ||
return (...args) => { | ||
HandledPromise.applyMethodSendOnly(x, p, args); | ||
HandledPromise.applyMethodSendOnly(x, p, harden(args)); | ||
return undefined; | ||
@@ -71,3 +71,3 @@ }; | ||
apply(_target, _thisArg, argsArray = []) { | ||
HandledPromise.applyFunctionSendOnly(x, argsArray); | ||
HandledPromise.applyFunctionSendOnly(x, harden(argsArray)); | ||
return undefined; | ||
@@ -74,0 +74,0 @@ }, |
@@ -282,5 +282,4 @@ // @ts-check | ||
// local handled Promise. | ||
[pendingHandler, continueForwarding] = makePostponedHandler( | ||
HandledPromise, | ||
); | ||
[pendingHandler, continueForwarding] = | ||
makePostponedHandler(HandledPromise); | ||
} | ||
@@ -430,3 +429,3 @@ | ||
// Resolving a Presence returns the pre-registered handled promise. | ||
let resolvedPromise = presenceToPromise.get(value); | ||
let resolvedPromise = presenceToPromise.get(/** @type {any} */ (value)); | ||
if (!resolvedPromise) { | ||
@@ -567,3 +566,5 @@ resolvedPromise = Promise.resolve(value); | ||
const unknownBaseHandledPromise = baseHandledPromise; | ||
HandledPromise = /** @type {typeof HandledPromise} */ (unknownBaseHandledPromise); | ||
HandledPromise = /** @type {typeof HandledPromise} */ ( | ||
unknownBaseHandledPromise | ||
); | ||
@@ -570,0 +571,0 @@ // We cannot harden(HandledPromise) because we're a vetted shim which |
@@ -14,7 +14,5 @@ /* eslint-disable no-shadow,no-unused-vars,no-use-before-define,no-var,vars-on-top */ | ||
: T extends Record<string | number | symbol, Function> | ||
? ERef< | ||
{ | ||
[K in keyof T]: EOnly<T[K]>; | ||
} | ||
> | ||
? ERef<{ | ||
[K in keyof T]: EOnly<T[K]>; | ||
}> | ||
: ERef<T>; | ||
@@ -21,0 +19,0 @@ |
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
Manifest confusion
Supply chain riskThis package has inconsistent metadata. This could be malicious or caused by an error when publishing the package.
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
Manifest confusion
Supply chain riskThis package has inconsistent metadata. This could be malicious or caused by an error when publishing the package.
Found 1 instance in 1 package
4
68657
1023