expresso-macchiato 0.3.8-dev.3 → 0.3.8-dev.4

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.js CHANGED
@@ -719,7 +719,7 @@ var SocketWrapper = class {
719
719
  if (!this.data.listeners) throw new Error("No listeners provided");
720
720
  this.namespace = io.of(`/${this.socketNamespace}`);
721
721
  if (this.data.connectionMiddleware) {
722
- io.use(async (client, next) => {
722
+ this.namespace.use(async (client, next) => {
723
723
  const commId = client.handshake.query.commId;
724
724
  const metadata = client.handshake.query.metadata;
725
725
  const beforeResult = await this.data.connectionMiddleware(this, client, commId, metadata);
@@ -731,7 +731,7 @@ var SocketWrapper = class {
731
731
  next();
732
732
  });
733
733
  }
734
- io.on("connection", (client) => {
734
+ this.namespace.on("connection", (client) => {
735
735
  try {
736
736
  if (!this.namespace) throw new Error("Socket.IO not initialized");
737
737
  const metadata = client.handshake.query.metadata;
package/dist/index.mjs CHANGED
@@ -719,7 +719,7 @@ var SocketWrapper = class {
719
719
  if (!this.data.listeners) throw new Error("No listeners provided");
720
720
  this.namespace = io.of(`/${this.socketNamespace}`);
721
721
  if (this.data.connectionMiddleware) {
722
- io.use(async (client, next) => {
722
+ this.namespace.use(async (client, next) => {
723
723
  const commId = client.handshake.query.commId;
724
724
  const metadata = client.handshake.query.metadata;
725
725
  const beforeResult = await this.data.connectionMiddleware(this, client, commId, metadata);
@@ -731,7 +731,7 @@ var SocketWrapper = class {
731
731
  next();
732
732
  });
733
733
  }
734
- io.on("connection", (client) => {
734
+ this.namespace.on("connection", (client) => {
735
735
  try {
736
736
  if (!this.namespace) throw new Error("Socket.IO not initialized");
737
737
  const metadata = client.handshake.query.metadata;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "expresso-macchiato",
3
- "version": "0.3.8-dev.3",
3
+ "version": "0.3.8-dev.4",
4
4
  "author": "Alessio Velluso",
5
5
  "license": "MIT",
6
6
  "description": "Description",