Skip to content

Commit

Permalink
Merge branch 'fix-ws-url' into 'main'
Browse files Browse the repository at this point in the history
Fix websocket URL builder HTTPS

See merge request reportcreator/reportcreator!483
  • Loading branch information
MWedl committed Mar 15, 2024
2 parents 2c14404 + 7d7274a commit c532cf9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion frontend/src/utils/collab.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ export function useCollab(storeState: CollabStoreState<any>) {
return;
}

const serverUrl = `${window.location.protocol === 'https' ? 'wss' : 'ws'}://${window.location.host}/`;
const serverUrl = `${window.location.protocol === 'http:' ? 'ws' : 'wss'}://${window.location.host}/`;
const wsUrl = urlJoin(serverUrl, storeState.websocketPath);
storeState.perPathState.clear();
storeState.connectionState = CollabConnectionState.CONNECTING;
Expand Down

0 comments on commit c532cf9

Please sign in to comment.