File tree 1 file changed +5
-3
lines changed
src/Illuminate/Foundation/Console
1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -49,10 +49,10 @@ public function handle()
49
49
$ this ->components ->info ("Published 'channels' route file. " );
50
50
51
51
copy (__DIR__ .'/stubs/broadcasting-routes.stub ' , $ broadcastingRoutesPath );
52
-
53
- $ this ->uncommentChannelsRoutesFile ();
54
52
}
55
53
54
+ $ this ->uncommentChannelsRoutesFile ();
55
+
56
56
// Install bootstrapping...
57
57
if (! file_exists ($ echoScriptPath = $ this ->laravel ->resourcePath ('js/echo.js ' ))) {
58
58
copy (__DIR__ .'/stubs/echo-js.stub ' , $ echoScriptPath );
@@ -63,7 +63,7 @@ public function handle()
63
63
$ bootstrapScriptPath
64
64
);
65
65
66
- if (! str_contains ($ bootstrapScript , '/echo ' )) {
66
+ if (! str_contains ($ bootstrapScript , '. /echo ' )) {
67
67
file_put_contents (
68
68
$ bootstrapScriptPath ,
69
69
trim ($ bootstrapScript .PHP_EOL .file_get_contents (__DIR__ .'/stubs/echo-bootstrap-js.stub ' )).PHP_EOL ,
@@ -93,6 +93,8 @@ protected function uncommentChannelsRoutesFile()
93
93
'channels: ' ,
94
94
$ appBootstrapPath ,
95
95
);
96
+ } elseif (str_contains ($ content , 'channels: ' )) {
97
+ return ;
96
98
} elseif (str_contains ($ content , 'commands: __DIR__. \'/../routes/console.php \', ' )) {
97
99
(new Filesystem )->replaceInFile (
98
100
'commands: __DIR__. \'/../routes/console.php \', ' ,
You can’t perform that action at this time.
0 commit comments