diff --git a/patches/medooze-spacebar-wrtc+1.0.6.patch b/patches/medooze-spacebar-wrtc+1.0.6.patch index eb9bb706..47cdc4f2 100644 --- a/patches/medooze-spacebar-wrtc+1.0.6.patch +++ b/patches/medooze-spacebar-wrtc+1.0.6.patch @@ -1,3 +1,20 @@ +diff --git a/node_modules/medooze-spacebar-wrtc/dist/MedoozeSignalingDelegate.js b/node_modules/medooze-spacebar-wrtc/dist/MedoozeSignalingDelegate.js +index e8f2986..b29578e 100644 +--- a/node_modules/medooze-spacebar-wrtc/dist/MedoozeSignalingDelegate.js ++++ b/node_modules/medooze-spacebar-wrtc/dist/MedoozeSignalingDelegate.js +@@ -28,9 +28,9 @@ class MedoozeSignalingDelegate { + join(roomId, userId, ws, type) { + // if this is guild-voice or dm-voice, make sure user isn't already in a room of those types + // user can be in many simultanous go live stream rooms though (can be in a voice channel and watching a stream for example, or watching multiple streams) +- const rooms = type === "stream" ? [] : this.rooms +- .values() +- .filter((room) => room.type === "dm-voice" || room.type === "guild-voice"); ++ const rooms = type === "stream" ? [] : Array.from(this.rooms.values()).filter((room) => ++ room.type === "dm-voice" || room.type === "guild-voice" ++ ); + let existingClient; + for (const room of rooms) { + let result = room.getClientById(userId); diff --git a/node_modules/medooze-spacebar-wrtc/src/MedoozeSignalingDelegate.ts b/node_modules/medooze-spacebar-wrtc/src/MedoozeSignalingDelegate.ts index 76213eb..1cca6ef 100644 --- a/node_modules/medooze-spacebar-wrtc/src/MedoozeSignalingDelegate.ts diff --git a/src/api/util/handlers/Instance.ts b/src/api/util/handlers/Instance.ts index ccd56d92..d371c2f0 100644 --- a/src/api/util/handlers/Instance.ts +++ b/src/api/util/handlers/Instance.ts @@ -34,5 +34,5 @@ export async function initInstance() { // } // TODO: do no clear sessions for instance cluster - await Session.delete({}); + await Session.createQueryBuilder().delete().execute(); }