1
0
Fork 0
mirror of https://github.com/archtechx/tenancy.git synced 2025-12-12 21:54:03 +00:00

Merge branch '2.x' of github.com:stancl/tenancy into 2.x

This commit is contained in:
Samuel Štancl 2020-04-25 01:30:40 +02:00
commit 03e21621a0
3 changed files with 7 additions and 3 deletions

View file

@ -30,5 +30,5 @@ The repository with the documentation source code can be found here: [stancl/ten
### Credits ### Credits
- Created by [Samuel Štancl](https://github.com/stancl) - Created by [Samuel Štancl](https://twitter.com/samuelstancl)
- Logo by [Caneco](https://twitter.com/caneco) - Logo by [Brian Dillingham](https://twitter.com/dillinghammm)

View file

@ -67,7 +67,7 @@ return [
], ],
/** /**
* Controller namespace used for routes in routes/tenant.php. * Controller namespace used by routes in routes/tenant.php.
*/ */
'tenant_route_namespace' => 'App\Http\Controllers', 'tenant_route_namespace' => 'App\Http\Controllers',

View file

@ -31,6 +31,10 @@ class TelescopeTags implements Feature
Telescope::tag(function (IncomingEntry $entry) { Telescope::tag(function (IncomingEntry $entry) {
$tags = $this->getTags($entry); $tags = $this->getTags($entry);
if (! request()->route()) {
return $tags;
}
$tenantRoute = PreventAccessFromTenantDomains::routeHasMiddleware(request()->route(), 'tenancy') $tenantRoute = PreventAccessFromTenantDomains::routeHasMiddleware(request()->route(), 'tenancy')
|| PreventAccessFromTenantDomains::routeHasMiddleware(request()->route(), 'universal'); || PreventAccessFromTenantDomains::routeHasMiddleware(request()->route(), 'universal');