feature/IO-3096-GlobalNotifications - Check-point

This commit is contained in:
Dave Richer
2025-02-10 15:19:41 -05:00
parent ba2d03176f
commit b1ffbe0e12
8 changed files with 262 additions and 70 deletions

View File

@@ -39,10 +39,9 @@ const redisSocketEvents = ({
const registerSocketEvents = (socket) => {
// Uncomment for further testing
// createLogEvent(socket, "debug", `Registering RedisIO Socket Events.`);
getUserSocketMapping(socket.user.email).then((socketIds) => {
console.log(socketIds);
});
// getUserSocketMapping(socket.user.email).then((socketIds) => {
// console.log(socketIds);
// });
// Token Update Events
const registerUpdateEvents = (socket) => {
@@ -62,7 +61,7 @@ const redisSocketEvents = ({
// Update the session data in Redis with the new token info
// await setSessionData(socket.id, "user", user);
// Update the mapping with the user's email
// await addUserSocketMapping(user.email, socket.id);
await addUserSocketMapping(user.email, socket.id);
createLogEvent(socket, "debug", `Token updated successfully for socket ID: ${socket.id}`);
socket.emit("token-updated", { success: true });
} catch (error) {