Skip to content
This repository was archived by the owner on Oct 23, 2024. It is now read-only.

Commit 62fd9c4

Browse files
authored
Deep clone data before notify to clients (#1335)
1 parent 6ee914c commit 62fd9c4

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

source/portal/socketIOServer.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -487,7 +487,8 @@ var SocketIOServer = function(spec, portal, observer) {
487487
log.debug('receivers:', JSON.stringify(receivers));
488488
for (let clientId of receivers) {
489489
if (!excludeList.includes(clientId) && clients[clientId]) {
490-
clients[clientId].notify(event, data);
490+
let dataClone = JSON.parse(JSON.stringify(data));
491+
clients[clientId].notify(event, dataClone);
491492
}
492493
}
493494
}

0 commit comments

Comments
 (0)