Skip to content
This repository was archived by the owner on Oct 30, 2024. It is now read-only.

Commit 87d762b

Browse files
committed
TASK: Use random string generator in Connection::subscribe method
1 parent c4e1c7c commit 87d762b

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/Connection.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -306,7 +306,7 @@ public function publish($subject, $payload = null)
306306
*/
307307
public function subscribe($subject, \Closure $callback)
308308
{
309-
$sid = uniqid();
309+
$sid = $this->randomGenerator->generateString(16);
310310
$msg = 'SUB '.$subject.' '.$sid;
311311
$this->send($msg);
312312
$this->subscriptions[$sid] = $callback;

0 commit comments

Comments
 (0)