@agoric/internal 0.2.2-dev-0fc1914.0 → 0.2.2-dev-eb0553c.0
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/package.json +3 -3
- package/src/callback.d.ts.map +1 -1
- package/src/callback.js +3 -6
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@agoric/internal",
|
|
3
|
-
"version": "0.2.2-dev-
|
|
3
|
+
"version": "0.2.2-dev-eb0553c.0+eb0553c",
|
|
4
4
|
"description": "Externally unsupported utilities internal to agoric-sdk",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "src/index.js",
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
"lint:types": "tsc -p jsconfig.json"
|
|
21
21
|
},
|
|
22
22
|
"dependencies": {
|
|
23
|
-
"@agoric/zone": "0.1.1-dev-
|
|
23
|
+
"@agoric/zone": "0.1.1-dev-eb0553c.0+eb0553c",
|
|
24
24
|
"@endo/far": "^0.2.18",
|
|
25
25
|
"@endo/marshal": "^0.8.5",
|
|
26
26
|
"@endo/patterns": "^0.2.2",
|
|
@@ -42,5 +42,5 @@
|
|
|
42
42
|
"publishConfig": {
|
|
43
43
|
"access": "public"
|
|
44
44
|
},
|
|
45
|
-
"gitHead": "
|
|
45
|
+
"gitHead": "eb0553c2b571531b60768f890a7e56de2b41c15f"
|
|
46
46
|
}
|
package/src/callback.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"callback.d.ts","sourceRoot":"","sources":["callback.js"],"names":[],"mappings":"AAuDO,6CALiB,OAAO,EAAE,KAAK,GAAG,sFAWxC;AAWM,0CALiB,OAAO,EAAE,KAAK,GAAG,oGAWxC;AAaM,6DAPiB,OAAO,EAAE,KAAK,GAAG,2JAaxC;AAeM,yDATiB,OAAO,EAAE,KAAK,GAAG,2MAexC;AAiBM,2DAXiB,OAAO,EAAE,KAAK,GAAG,iOAoBxC;AAiBM,uDAXiB,OAAO,EAAE,KAAK,GAAG,iRAmBxC;AAOM,qCAHI,GAAG,+CAeb;AAcM,+DAPI,OAAO,cAAc,EAAE,IAAI;IAGL,cAAc;IAEtB,GAAG;;
|
|
1
|
+
{"version":3,"file":"callback.d.ts","sourceRoot":"","sources":["callback.js"],"names":[],"mappings":"AAuDO,6CALiB,OAAO,EAAE,KAAK,GAAG,sFAWxC;AAWM,0CALiB,OAAO,EAAE,KAAK,GAAG,oGAWxC;AAaM,6DAPiB,OAAO,EAAE,KAAK,GAAG,2JAaxC;AAeM,yDATiB,OAAO,EAAE,KAAK,GAAG,2MAexC;AAiBM,2DAXiB,OAAO,EAAE,KAAK,GAAG,iOAoBxC;AAiBM,uDAXiB,OAAO,EAAE,KAAK,GAAG,iRAmBxC;AAOM,qCAHI,GAAG,+CAeb;AAcM,+DAPI,OAAO,cAAc,EAAE,IAAI;IAGL,cAAc;IAEtB,GAAG;;aAkEb,GAAG;;;2BAxDgB,GAAG,WAAW,OAAO,EAAE,KAAK,GAAG,4EAA/B,GAAG,WAAW,OAAO,EAAE,KAAK,GAAG,KA2FhE;AAWM,+CALI,OAAO,cAAc,EAAE,IAAI,kBAC3B,cAAc;;oCAYxB;;yCA5SuB,OAAO,EAAE,KAAK,GAAG,IAC5B,OAAO,SAAS,EAAE,QAAQ,CAAC,CAAC,CAAC;6CAIlB,OAAO,EAAE,KAAK,GAAG,IAC5B,OAAO,SAAS,EAAE,YAAY,CAAC,CAAC,CAAC;yBAGpB,OAAO,qBAAqB,EAAE,cAAc,CAAC,EAAE,EAAE,CAAC,CAAC,GAAG,CAAC"}
|
package/src/callback.js
CHANGED
|
@@ -245,8 +245,6 @@ export const prepareAttenuator = (
|
|
|
245
245
|
)
|
|
246
246
|
);
|
|
247
247
|
|
|
248
|
-
const methodKeys = /** @type {(keyof Methods)[]} */ (ownKeys(methods));
|
|
249
|
-
|
|
250
248
|
/**
|
|
251
249
|
* Create an exo object whose behavior is composed from a default target
|
|
252
250
|
* and/or individual method override callbacks.
|
|
@@ -277,17 +275,16 @@ export const prepareAttenuator = (
|
|
|
277
275
|
}) => {
|
|
278
276
|
const cbs = /** @type {Overrides} */ ({});
|
|
279
277
|
|
|
280
|
-
const remaining = new Set(
|
|
278
|
+
const remaining = new Set(methodNames);
|
|
281
279
|
for (const key of ownKeys(overrides)) {
|
|
282
280
|
remaining.has(key) ||
|
|
283
281
|
Fail`${q(tag)} overrides[${q(key)}] not allowed by methodNames`;
|
|
284
282
|
|
|
285
283
|
remaining.delete(key);
|
|
286
284
|
const cb = overrides[key];
|
|
287
|
-
|
|
285
|
+
cb == null ||
|
|
288
286
|
isCallback(cb) ||
|
|
289
|
-
|
|
290
|
-
}
|
|
287
|
+
Fail`${q(tag)} overrides[${q(key)}] is not a callback; got ${cb}`;
|
|
291
288
|
cbs[key] = cb;
|
|
292
289
|
}
|
|
293
290
|
for (const key of remaining) {
|