From 021ec1b531ec375f5a17c266acd45bd05c9c08fa Mon Sep 17 00:00:00 2001 From: Nicholas Kariniemi Date: Fri, 1 May 2015 08:56:37 +0300 Subject: [PATCH] Use /ws path for websocket connections - Less confusion around upgrading HTTP connections to WebSocket --- src/cljs/grub/websocket.cljs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/cljs/grub/websocket.cljs b/src/cljs/grub/websocket.cljs index cf67309..9853414 100644 --- a/src/cljs/grub/websocket.cljs +++ b/src/cljs/grub/websocket.cljs @@ -11,7 +11,7 @@ (def protocol (.-protocol location)) (def ws-protocol (if (= protocol "http:") "ws://" "wss://")) (def host (.-host location)) -(def path (.-pathname location)) +(def path (str (.-pathname location) "ws")) (def server-url (str ws-protocol host path)) (def reader (t/reader :json)) (def writer (t/writer :json))