@paynext/sdk 0.0.64 → 0.0.66

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/index.es.js CHANGED
@@ -17889,18 +17889,20 @@ class Wu {
17889
17889
  class Ju {
17890
17890
  constructor(e) {
17891
17891
  A(this, "parent");
17892
- A(this, "core", new Wu());
17893
- this.parent = e;
17892
+ A(this, "core");
17893
+ typeof window != "undefined" && (this.parent = e, this.core = new Wu());
17894
17894
  }
17895
17895
  mount(e) {
17896
17896
  return H(this, null, function* () {
17897
+ if (!this.parent || !this.core)
17898
+ return;
17897
17899
  const a = yield this.core.checkout.mount();
17898
17900
  this.parent.innerHTML = "", this.parent.appendChild(a), this.core.state.checkout.setState(e);
17899
17901
  });
17900
17902
  }
17901
17903
  unmount() {
17902
17904
  return H(this, null, function* () {
17903
- this.parent.innerHTML = "", this.core.clearState();
17905
+ !this.parent || !this.core || (this.parent.innerHTML = "", this.core.clearState());
17904
17906
  });
17905
17907
  }
17906
17908
  }