mol_wire_lib 1.0.293 → 1.0.294

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.js CHANGED
@@ -695,7 +695,7 @@ var $;
695
695
  return res;
696
696
  };
697
697
  result = Object.assign(result.then(put, put), {
698
- destructor: result['destructor']
698
+ destructor: result['destructor'] ?? (() => { })
699
699
  });
700
700
  handled.add(result);
701
701
  }
@@ -712,7 +712,7 @@ var $;
712
712
  if (this.cache === result)
713
713
  this.absorb();
714
714
  }), {
715
- destructor: result['destructor']
715
+ destructor: result['destructor'] ?? (() => { })
716
716
  });
717
717
  handled.add(result);
718
718
  }
@@ -908,6 +908,8 @@ var $;
908
908
  };
909
909
  }
910
910
  complete() {
911
+ if (this.cache instanceof Promise)
912
+ return;
911
913
  this.destructor();
912
914
  }
913
915
  put(next) {
@@ -1087,7 +1089,9 @@ var $;
1087
1089
  try {
1088
1090
  next[Symbol.toStringTag] = this[Symbol.toStringTag];
1089
1091
  }
1090
- catch { }
1092
+ catch {
1093
+ Object.defineProperty(next, Symbol.toStringTag, { value: this[Symbol.toStringTag] });
1094
+ }
1091
1095
  }
1092
1096
  if (this.sub_from < this.data.length) {
1093
1097
  if (!$mol_compare_deep(prev, next)) {