From 114f8192ff953a51b6d3da0801e38f4cc1ff43f0 Mon Sep 17 00:00:00 2001 From: Mihaela Dumitru Date: Tue, 2 Apr 2024 18:52:17 +0300 Subject: [PATCH] fix(whiteboard) backend safe room hash --- react/features/whiteboard/functions.ts | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/react/features/whiteboard/functions.ts b/react/features/whiteboard/functions.ts index a04fbbd13bf7..bef5ff6feefe 100644 --- a/react/features/whiteboard/functions.ts +++ b/react/features/whiteboard/functions.ts @@ -6,7 +6,7 @@ import { getCurrentConference } from '../base/conference/functions'; import { IWhiteboardConfig } from '../base/config/configType'; import { getRemoteParticipants, isLocalParticipantModerator } from '../base/participants/functions'; import { encodeToBase64URL } from '../base/util/httpUtils'; -import { appendURLHashParam, appendURLParam } from '../base/util/uri'; +import { appendURLHashParam, appendURLParam, getBackendSafePath } from '../base/util/uri'; import { getCurrentRoomId, isInBreakoutRoom } from '../breakout-rooms/functions'; import { MIN_USER_LIMIT, USER_LIMIT_THRESHOLD, WHITEBOARD_ID, WHITEBOARD_PATH_NAME } from './constants'; @@ -98,7 +98,9 @@ export const getCollabServerUrl = (state: IReduxState): string | undefined => { const { locationURL } = state['features/base/connection']; const inBreakoutRoom = isInBreakoutRoom(state); const roomId = getCurrentRoomId(state); - const room = md5.hex(`${locationURL?.origin}${locationURL?.pathname}${inBreakoutRoom ? `|${roomId}` : ''}`); + const room = md5.hex( + `${locationURL?.origin}${getBackendSafePath(locationURL?.pathname)}${inBreakoutRoom ? `|${roomId}` : ''}` + ); return appendURLParam(collabServerBaseUrl, 'room', room); };