diff options
author | Alex Auvolat <alex@adnab.me> | 2018-09-26 15:59:22 +0200 |
---|---|---|
committer | Alex Auvolat <alex@adnab.me> | 2018-09-26 15:59:22 +0200 |
commit | 1a13285971ef728109011a93e676e26248b30242 (patch) | |
tree | f03467bc07ff84961f8c3eb88497adaf36b5f009 /shardweb/assets/js/socket.js | |
parent | 7d0009d83c9b5c747d4adb535817924762429f30 (diff) | |
download | shard-1a13285971ef728109011a93e676e26248b30242.tar.gz shard-1a13285971ef728109011a93e676e26248b30242.zip |
Fixes
Diffstat (limited to 'shardweb/assets/js/socket.js')
-rw-r--r-- | shardweb/assets/js/socket.js | 3 |
1 files changed, 2 insertions, 1 deletions
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`, |