Nice
All checks were successful
Deploy Encrypted Todo App / build-and-push (push) Successful in 4m16s

This commit is contained in:
2025-06-16 11:13:35 -06:00
parent a665af0c4c
commit b5f2296ade
2 changed files with 4 additions and 1 deletions

View File

@ -75,8 +75,10 @@
function connectWebSocket() {
if (!currentUser) return;
const protocol =
window.location.protocol === "https:" ? "wss:" : "ws:";
ws = new WebSocket(
`ws://${window.location.host}?userId=${currentUser}`,
`${protocol}//${window.location.host}?userId=${currentUser}`,
);
ws.onmessage = (event) => {
const msg = JSON.parse(event.data);