@ejfdelgado/ejflab-back 1.17.3 → 1.18.0

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ejfdelgado/ejflab-back",
3
- "version": "1.17.3",
3
+ "version": "1.18.0",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "git+https://github.com/ejfdelgado/ejflab-back.git"
@@ -45,6 +45,7 @@ export class SocketIOCall {
45
45
  static mapFlowChartExec = {};
46
46
  static socketIdToSocket = {};
47
47
  static socketRoomUUIDMap = {};
48
+ static socketToImage = {};
48
49
 
49
50
  static echoLog(message) {
50
51
  console.log(message);
@@ -274,6 +275,9 @@ export class SocketIOCall {
274
275
  SocketIOCall.echoLog(`${socket.id} sends disconnect with ${JSON.stringify(payload)}`);
275
276
  new DisconnectProcessor(SocketIOCall, SocketIOCall.io, socket).executeSave(payload);
276
277
  SocketIOCall.disconnect(socket);
278
+ if (socket.id in SocketIOCall.socketToImage) {
279
+ delete SocketIOCall.socketToImage[socket.id];
280
+ }
277
281
  });
278
282
  /*
279
283
  socket.on("reconnect", (payload) => {
@@ -520,4 +524,12 @@ export class SocketIOCall {
520
524
  };
521
525
  res.status(200).send(response);
522
526
  }
527
+
528
+ static putSocketImage(socketId, bytes) {
529
+ SocketIOCall.socketToImage[socketId] = bytes;
530
+ }
531
+
532
+ static getSocketImage(socketId) {
533
+ return SocketIOCall.socketToImage[socketId];
534
+ }
523
535
  }