1
0
Fork 0
mirror of https://github.com/archtechx/tenancy.git synced 2025-12-12 22:54:03 +00:00
This commit is contained in:
Samuel Štancl 2020-12-14 13:12:03 +01:00 committed by GitHub
parent faedc849c9
commit 1fbe9cf3e2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -15,6 +15,9 @@ use Stancl\Tenancy\Middleware;
class TenancyServiceProvider extends ServiceProvider class TenancyServiceProvider extends ServiceProvider
{ {
// By default, no namespace is used to support the callable array syntax.
public static string $controllerNamespace = '';
public function events() public function events()
{ {
return [ return [
@ -118,7 +121,7 @@ class TenancyServiceProvider extends ServiceProvider
protected function mapRoutes() protected function mapRoutes()
{ {
if (file_exists(base_path('routes/tenant.php'))) { if (file_exists(base_path('routes/tenant.php'))) {
Route::namespace('App\Http\Controllers') Route::namespace(static::$controllerNamespace)
->group(base_path('routes/tenant.php')); ->group(base_path('routes/tenant.php'));
} }
} }