This commit is contained in:
Samuel Štancl 2020-06-13 14:40:30 +02:00
parent 14d1a0fc17
commit 5f2470fad9
2 changed files with 12 additions and 0 deletions

View file

@ -96,3 +96,13 @@ InitializeTenancyByRequestData::$queryParameter = null;
## Manually identifying tenants
See the [manual initialization page]({{ $page->link('manual-initialization') }}) to see how to identify tenants manually.
## Customizing onFail logic
Each identification middleware has a static `$onFail` property that can be used to customize the behavior that should happen when a tenant couldn't be identified.
```php
\Stancl\Tenancy\Middleware\InitializeTenancyByDomain::$onFail = function ($exception, $request, $next) {
return redirect('https://my-central-domain.com/');
};
```