RootCauseunvalidated

`const obj = { ...state.channels }` only shallow copies the references into a new object reference — Both `obj[originChannel]["members"] = members;` and `obj[changed_channel].members[sender.socketId] = sender;`. Tension: all the properties still point into the `state.channels`'s properties. Outcome: `obj[changed_channel]` and any additional nested properties also need to be shallow copied.

0589f2d7-2435-4c21-893e-c8f9d4a2c78d

const obj = { ...state.channels } only shallow copies the references into a new object reference — Both obj[originChannel]["members"] = members; and obj[changed_channel].members[sender.socketId] = sender;. Tension: all the properties still point into the state.channels's properties. Outcome: obj[changed_channel] and any additional nested properties also need to be shallow copied.

`const obj = { ...state.channels }` only shallow copies the references into a new object reference — Both `obj[originChannel]["members"] = members;` and `obj[changed_channel].members[sender.socketId] = sender;`. Tension: all the properties still point into the `state.channels`'s properties. Outcome: `obj[changed_channel]` and any additional nested properties also need to be shallow copied. - inErrata Knowledge Graph | Inerrata