diff --git a/src/SocialstreamServiceProvider.php b/src/SocialstreamServiceProvider.php index b4c87b97..0b4da4d0 100644 --- a/src/SocialstreamServiceProvider.php +++ b/src/SocialstreamServiceProvider.php @@ -166,6 +166,21 @@ protected function bootLaravelBreeze(): void return; } + // Routes + if (class_exists('\App\Providers\VoltServiceProvider')) { + return; + } elseif (class_exists('\App\Http\Middleware\HandleInertiaRequests')) { + $this->publishes(paths: [ + __DIR__.'/../stubs/breeze/inertia-common/routes/auth.php' => base_path('routes/auth.php'), + __DIR__.'/../stubs/breeze/inertia-common/routes/web.php' => base_path('routes/web.php'), + ], groups: 'socialstream-routes'); + } elseif (class_exists('\App\Http\Controllers\ProfileController')) { + $this->publishes(paths: [ + __DIR__.'/../stubs/breeze/default/routes/auth.php' => base_path('routes/auth.php'), + __DIR__.'/../stubs/breeze/default/routes/web.php' => base_path('routes/web.php'), + ], groups: 'socialstream-routes'); + } + // Migrations $this->publishes([ __DIR__.'/../database/migrations/2014_10_12_000000_create_breeze_users_table.php' => database_path('migrations/2014_10_12_000000_create_users_table.php'), @@ -213,21 +228,6 @@ protected function bootLaravelJetstream(): void ], 'socialstream-routes'); } - // Routes - if (class_exists('\App\Providers\VoltServiceProvider')) { - return; - } elseif (class_exists('\App\Http\Middleware\HandleInertiaRequests')) { - $this->publishes(paths: [ - __DIR__.'/../stubs/breeze/inertia-common/routes/auth.php' => base_path('routes/auth.php'), - __DIR__.'/../stubs/breeze/inertia-common/routes/web.php' => base_path('routes/web.php'), - ], groups: 'socialstream-routes'); - } elseif (class_exists('\App\Http\Controllers\ProfileController')) { - $this->publishes(paths: [ - __DIR__.'/../stubs/breeze/default/routes/auth.php' => base_path('routes/auth.php'), - __DIR__.'/../stubs/breeze/default/routes/web.php' => base_path('routes/web.php'), - ], groups: 'socialstream-routes'); - } - // Actions $this->publishes(array_merge([ __DIR__.'/../stubs/app/Actions/Socialstream/' => app_path('Actions/Socialstream/'),