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

Return the result of onFail closures in middleware

This commit is contained in:
Samuel Štancl 2020-04-06 11:14:05 +02:00
parent 5dc80473d3
commit 4f5ef6fc56
2 changed files with 2 additions and 2 deletions

View file

@ -36,7 +36,7 @@ class InitializeTenancy
try { try {
tenancy()->init($request->getHost()); tenancy()->init($request->getHost());
} catch (TenantCouldNotBeIdentifiedException $e) { } catch (TenantCouldNotBeIdentifiedException $e) {
($this->onFail)($e); return ($this->onFail)($e);
} }
} }

View file

@ -41,7 +41,7 @@ class InitializeTenancyByRequestData
try { try {
$this->initializeTenancy($request); $this->initializeTenancy($request);
} catch (TenantCouldNotBeIdentifiedException $e) { } catch (TenantCouldNotBeIdentifiedException $e) {
($this->onFail)($e); return ($this->onFail)($e);
} }
} }