From 1a13285971ef728109011a93e676e26248b30242 Mon Sep 17 00:00:00 2001 From: Alex Auvolat Date: Wed, 26 Sep 2018 15:59:22 +0200 Subject: Fixes --- shardweb/assets/js/socket.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'shardweb/assets') diff --git a/shardweb/assets/js/socket.js b/shardweb/assets/js/socket.js index 5088721..4c340f0 100644 --- a/shardweb/assets/js/socket.js +++ b/shardweb/assets/js/socket.js @@ -5,7 +5,8 @@ // and connect at the socket path in "lib/web/endpoint.ex": import {Socket} from "phoenix" -let socket = new Socket("/socket", {params: {token: window.userToken}}) +let pk = window.Gon.getAsset('pk'); +let socket = new Socket("/socket", {params: {token: window.userToken, pk: pk}}) // When you connect, you'll often need to authenticate the client. // For example, imagine you have an authentication plug, `MyAuth`, -- cgit v1.2.3