@interncom/diplomatic 0.0.22 → 0.0.23

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.
Files changed (2) hide show
  1. package/dist/index.mjs +4 -2
  2. package/package.json +1 -1
package/dist/index.mjs CHANGED
@@ -8819,8 +8819,10 @@ var DiplomaticClient = class {
8819
8819
  };
8820
8820
  this.websocket.onclose = (e) => {
8821
8821
  console.log("DISCONNECTED");
8822
- this.connect(hostURL);
8823
- this.emitUpdate();
8822
+ if (navigator.onLine) {
8823
+ this.connect(hostURL);
8824
+ this.emitUpdate();
8825
+ }
8824
8826
  };
8825
8827
  this.websocket.onmessage = (e) => {
8826
8828
  console.log(`RECEIVED: ${e.data}`);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@interncom/diplomatic",
3
- "version": "0.0.22",
3
+ "version": "0.0.23",
4
4
  "type": "module",
5
5
  "description": "Secure sync layer",
6
6
  "main": "dist/index.mjs",