mirror of
https://github.com/archtechx/tenancy.git
synced 2025-12-12 17:44:04 +00:00
Return the result of onFail closures in middleware
This commit is contained in:
parent
5dc80473d3
commit
4f5ef6fc56
2 changed files with 2 additions and 2 deletions
|
|
@ -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);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -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);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue