mol_crypto_lib 0.1.1449 → 0.1.1450

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/node.mjs CHANGED
@@ -1197,9 +1197,18 @@ var $;
1197
1197
  }
1198
1198
  destructor() {
1199
1199
  super.destructor();
1200
- if ($mol_owning_check(this, this.cache)) {
1200
+ if (!$mol_owning_check(this, this.cache))
1201
+ return;
1202
+ try {
1201
1203
  this.cache.destructor();
1202
1204
  }
1205
+ catch (result) {
1206
+ if ($mol_promise_like(result)) {
1207
+ const error = new Error(`Promise in ${this}.destructor()`);
1208
+ Object.defineProperty(result, 'stack', { get: () => error.stack });
1209
+ }
1210
+ $mol_fail_hidden(result);
1211
+ }
1203
1212
  }
1204
1213
  }
1205
1214
  $.$mol_wire_fiber = $mol_wire_fiber;
package/node.test.js CHANGED
@@ -1188,9 +1188,18 @@ var $;
1188
1188
  }
1189
1189
  destructor() {
1190
1190
  super.destructor();
1191
- if ($mol_owning_check(this, this.cache)) {
1191
+ if (!$mol_owning_check(this, this.cache))
1192
+ return;
1193
+ try {
1192
1194
  this.cache.destructor();
1193
1195
  }
1196
+ catch (result) {
1197
+ if ($mol_promise_like(result)) {
1198
+ const error = new Error(`Promise in ${this}.destructor()`);
1199
+ Object.defineProperty(result, 'stack', { get: () => error.stack });
1200
+ }
1201
+ $mol_fail_hidden(result);
1202
+ }
1194
1203
  }
1195
1204
  }
1196
1205
  $.$mol_wire_fiber = $mol_wire_fiber;