stelar-time-real 1.2.2 → 1.2.3

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/README.md CHANGED
@@ -558,6 +558,9 @@ client.emitBinary('upload', fileData);
558
558
 
559
559
  ## Changelog
560
560
 
561
+ ### v1.2.3
562
+ - Cleanup: código fantasma eliminado (_parent, _children, _externalServer)
563
+
561
564
  ### v1.2.2
562
565
  - Bugfix: métodos duplicados en client.js
563
566
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "stelar-time-real",
3
- "version": "1.2.2",
3
+ "version": "1.2.3",
4
4
  "description": "WebSocket liviano y rápido sin dependecias. Alternativa a socket.io, namespaces, ACKs y archivos binarios.",
5
5
  "main": "src/index.js",
6
6
  "type": "module",
package/src/index.js CHANGED
@@ -15,8 +15,6 @@ class StelarServer {
15
15
  this._wildcardHandler = null;
16
16
  this._connectionHandler = null;
17
17
  this._acks = {};
18
- this._parent = null;
19
- this._children = new Map();
20
18
  }
21
19
 
22
20
  static of(path, options = {}) {
@@ -273,6 +271,7 @@ class StelarServer {
273
271
  };
274
272
 
275
273
  if (this.server) {
274
+ this.server._isExternal = true;
276
275
  startServer(this.server);
277
276
  } else {
278
277
  const tryListen = (port) => {
@@ -300,7 +299,7 @@ class StelarServer {
300
299
  stop() {
301
300
  if (this._hbTimer) clearInterval(this._hbTimer);
302
301
  if (this.wss) this.wss.close();
303
- if (this.server && !this._externalServer) this.server.close();
302
+ if (this.server && !this.server._isExternal) this.server.close();
304
303
  return this;
305
304
  }
306
305
  }