You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I believe $this->uncommentChannelsRoutesFile(); should be called regardless of whether the channels.php file exists or not, and a check added to $this->uncommentChannelsRoutesFile(); to prevent duplication.
Steps To Reproduce
Have existing Laravel 10 app that uses broadcasting
Upgrade application to Laravel 11 including new bootstrap/app.php file
Run php artisan install:broadcasting to re-enable broadcasting
The expected changes to bootstrap/app.php are not made
The text was updated successfully, but these errors were encountered:
colincameron
changed the title
Installing broadcasting in doesn't add routes to bootstrap/app.php if route file exists
Installing broadcasting doesn't add routes to bootstrap/app.php if routes/channels.php file exists
Mar 13, 2024
Laravel Version
11
PHP Version
8.3
Database Driver & Version
No response
Description
After updating the application skeleton files to those included with Laravel 11, I ran
php artisan install:broadcasting
as instructed in https://laravel.com/docs/11.x/broadcasting#installationHowever, the broadcast routes were not registered in bootstrap/app.php as I already had the routes/channels.php file.
The
install:broadcasting
command does not add the routes to bootstrap/app.php if the channels.php file already exists:framework/src/Illuminate/Foundation/Console/BroadcastingInstallCommand.php
Line 53 in eac3418
I believe
$this->uncommentChannelsRoutesFile();
should be called regardless of whether the channels.php file exists or not, and a check added to$this->uncommentChannelsRoutesFile();
to prevent duplication.Steps To Reproduce
The text was updated successfully, but these errors were encountered: