This commit is contained in:
Matteo Rosati
2026-01-20 12:12:59 +01:00
parent c9b3f7d33c
commit f5bafd1117

View File

@@ -1,8 +1,7 @@
(($) => { (($) => {
const isSecure = location.protocol === "https:"; const isSecure = location.protocol === "https:";
const port = location.port ? `:${location.port}` : "";
var ws = new WebSocket( var ws = new WebSocket(
`ws${isSecure ? "s" : ""}://${location.host}${port}/ws`, `ws${isSecure ? "s" : ""}://${location.host}/ws`,
); );
const input = $("#message"); const input = $("#message");
const messages = $("#messages"); const messages = $("#messages");