1
0
Fork 0
mirror of https://github.com/archtechx/tenancy.git synced 2025-12-12 16:14:02 +00:00

Merge branch 'master' of github.com:stancl/tenancy

This commit is contained in:
Samuel Štancl 2020-05-29 09:35:54 +02:00
commit 16a598bb17
2 changed files with 7 additions and 3 deletions

View file

@ -1,5 +1,7 @@
<?php
declare(strict_types=1);
namespace Stancl\Tenancy\Features;
use Closure;
@ -38,7 +40,7 @@ class UniversalRoutes implements Feature
// groups have the searhced middleware group inside them
$middlewareGroups = Router::getMiddlewareGroups();
foreach ($route->gatherMiddleware() as $inner) {
if (!$inner instanceof Closure && isset($middlewareGroups[$inner]) && in_array($middleware, $middlewareGroups[$inner], true)) {
if (! $inner instanceof Closure && isset($middlewareGroups[$inner]) && in_array($middleware, $middlewareGroups[$inner], true)) {
return true;
}
}