I added better error display
This commit is contained in:
parent
556a5aba2e
commit
4f0dd41028
|
|
@ -41,6 +41,7 @@ class Handler implements MessageComponentInterface
|
||||||
|
|
||||||
public function onOpen(ConnectionInterface $connection)
|
public function onOpen(ConnectionInterface $connection)
|
||||||
{
|
{
|
||||||
|
try{
|
||||||
if (! $this->connectionCanBeMade($connection)) {
|
if (! $this->connectionCanBeMade($connection)) {
|
||||||
return $connection->close();
|
return $connection->close();
|
||||||
}
|
}
|
||||||
|
|
@ -70,6 +71,13 @@ class Handler implements MessageComponentInterface
|
||||||
$connection->socketId
|
$connection->socketId
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
}catch (UnknownAppKey $e) {
|
||||||
|
Log::channel('websocket')->error('Root level error: '. $e->getMessage(), [
|
||||||
|
'file' => $e->getFile(),
|
||||||
|
'line' => $e->getLine(),
|
||||||
|
'trace' => $e->getTraceAsString(),
|
||||||
|
]);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public function onMessage(
|
public function onMessage(
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue