Skip to content

Commit ce1c34c

Browse files
committed
Add event type
1 parent 75c2ba3 commit ce1c34c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Cmosguy/Broadcasting/Broadcasters/PushStreamBroadcaster.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,10 +36,10 @@ public function broadcast(array $channels, $event, array $payload = array())
3636

3737
foreach ($channels as $channel) {
3838
$payload = [
39-
'text' => $payload
39+
'text' => array_merge(['eventtype' => $event], $payload)
4040
];
4141
$request = $this->client->createRequest('POST', '/pub?id=' . $channel, ['json' => $payload]);
4242
$response = $this->client->send($request);
4343
}
4444
}
45-
}
45+
}

0 commit comments

Comments
 (0)