1
0
Fork 0
mirror of https://github.com/archtechx/tenancy.git synced 2025-12-12 09:34:04 +00:00

Stop setting $prefixRouteNames to true in path ID MW (#22)

* Stop setting $prefixRouteNames in path ID MW

* Fix code style (php-cs-fixer)

---------

Co-authored-by: PHP CS Fixer <phpcsfixer@example.com>
This commit is contained in:
lukinovec 2023-12-19 17:44:06 +01:00 committed by GitHub
parent ea5a7463b8
commit d9b63cdf59
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -10,7 +10,6 @@ use Stancl\Tenancy\Concerns\UsableWithEarlyIdentification;
use Stancl\Tenancy\Concerns\UsableWithUniversalRoutes;
use Stancl\Tenancy\Enums\RouteMode;
use Stancl\Tenancy\Exceptions\RouteIsMissingTenantParameterException;
use Stancl\Tenancy\Overrides\TenancyUrlGenerator;
use Stancl\Tenancy\Resolvers\PathTenantResolver;
use Stancl\Tenancy\Tenancy;
@ -38,9 +37,6 @@ class InitializeTenancyByPath extends IdentificationMiddleware implements Usable
return $next($request);
}
// Used with *route-level* identification, takes precedence over what may have been configured for global stack middleware
TenancyUrlGenerator::$prefixRouteNames = true;
// Only initialize tenancy if the route has the tenant parameter.
// We don't want to initialize tenancy if the tenant is
// simply injected into some route controller action.