vani-meeting-server 1.2.9 → 1.3.1
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.
|
@@ -173,7 +173,8 @@ class EachSocketConnectionHandler extends BaseSFUWebsocket_1.BaseSFUWebsocket {
|
|
|
173
173
|
if (paylod.data.shouldPresist && paylod.data.shouldPresist === true) {
|
|
174
174
|
RedisHandler_1.RedisHandler.getInstance().storeMesagesForRoom(this.selfParticipant.roomId, paylod.data.message);
|
|
175
175
|
}
|
|
176
|
-
|
|
176
|
+
const to = paylod.data.to === "all" ? this.selfParticipant?.roomId : paylod.data.to;
|
|
177
|
+
this.redisBroadcastMessageToTopic(to, this.preapreClientMessageBody(false, this.selfParticipant, this.preapreWebSocketMessageBody(paylod.data.type, paylod.data.message)));
|
|
177
178
|
}
|
|
178
179
|
else if (paylod.type === WebSocketBasicEvents.GetOldMessages) {
|
|
179
180
|
const messages = await RedisHandler_1.RedisHandler.getInstance().fetchMessagesForRoom(this.selfParticipant?.roomId);
|
|
@@ -286,7 +287,7 @@ class EachSocketConnectionHandler extends BaseSFUWebsocket_1.BaseSFUWebsocket {
|
|
|
286
287
|
if (meetingStartTime === undefined) {
|
|
287
288
|
const meetingTime = new Date().getTime();
|
|
288
289
|
RedisHandler_1.RedisHandler.getInstance().storeMeetingTimeForRoom(this.selfParticipant.roomId, meetingTime);
|
|
289
|
-
this.sendVaniEvent(Event_1.VaniEvent.OnNewMeetingStarted,
|
|
290
|
+
this.sendVaniEvent(Event_1.VaniEvent.OnNewMeetingStarted, this.selfParticipant.roomId);
|
|
290
291
|
return meetingTime;
|
|
291
292
|
}
|
|
292
293
|
return meetingStartTime;
|