Skip to content

Commit 612cb4a

Browse files
nenadsNenad Scekic
and
Nenad Scekic
authored
fix presence channel (georgeboot#15)
Co-authored-by: Nenad Scekic <nenad.scekic@skunkworksden.com>
1 parent 957ce4f commit 612cb4a

File tree

3 files changed

+5396
-5292
lines changed

3 files changed

+5396
-5292
lines changed

js-src/Websocket.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@ export class Websocket {
146146
event: 'subscribe',
147147
data: {
148148
channel: channel.name,
149-
auth: response.data.auth,
149+
... response.data
150150
},
151151
})
152152
}).catch((error) => {

src/Handler.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ protected function subscribe(WebsocketEvent $event, Context $context): void
9393
$data = "{$event->getConnectionId()}:{$channel}";
9494

9595
if ($channelData) {
96-
$data .= ':' . json_encode($channelData);
96+
$data .= ':' . $channelData;
9797
}
9898

9999
$signature = hash_hmac('sha256', $data, config('app.key'), false);

0 commit comments

Comments
 (0)