Skip to content

Commit

Permalink
add missing pathname to websocket url (#1167)
Browse files Browse the repository at this point in the history
  • Loading branch information
Athou committed Jan 1, 2024
1 parent bbbb9c1 commit d9a9a01
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion commafeed-client/src/hooks/useWebSocket.ts
Expand Up @@ -15,7 +15,7 @@ export const useWebSocket = () => {
if (websocketEnabled && websocketPingInterval) {
const currentUrl = new URL(window.location.href)
const wsProtocol = currentUrl.protocol === "http:" ? "ws" : "wss"
const wsUrl = `${wsProtocol}://${currentUrl.hostname}:${currentUrl.port}/ws`
const wsUrl = `${wsProtocol}://${currentUrl.hostname}:${currentUrl.port}${currentUrl.pathname}ws`

ws = new WebsocketHeartbeatJs({
url: wsUrl,
Expand Down

0 comments on commit d9a9a01

Please sign in to comment.