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

Commit 76e091d

Browse files
authored
Merge pull request #18 from pascalbaljet/master
Support for forcing debug mode
2 parents c42fb3b + 3aeddc0 commit 76e091d

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/Console/StartWebSocketServer.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919

2020
class StartWebSocketServer extends Command
2121
{
22-
protected $signature = 'websockets:serve {--host=0.0.0.0} {--port=6001} ';
22+
protected $signature = 'websockets:serve {--host=0.0.0.0} {--port=6001} {--debug : Forces the loggers to be enabled and thereby overriding the app.debug config setting } ';
2323

2424
protected $description = 'Start the Laravel WebSocket Server';
2525

@@ -71,7 +71,7 @@ protected function configureHttpLogger()
7171
{
7272
app()->singleton(HttpLogger::class, function () {
7373
return (new HttpLogger($this->output))
74-
->enable(config('app.debug'))
74+
->enable($this->option('debug') ?: config('app.debug'))
7575
->verbose($this->output->isVerbose());
7676
});
7777

@@ -82,7 +82,7 @@ protected function configureMessageLogger()
8282
{
8383
app()->singleton(WebsocketsLogger::class, function () {
8484
return (new WebsocketsLogger($this->output))
85-
->enable(config('app.debug'))
85+
->enable($this->option('debug') ?: config('app.debug'))
8686
->verbose($this->output->isVerbose());
8787
});
8888

0 commit comments

Comments
 (0)