mirror of
https://github.com/archtechx/tenancy.git
synced 2025-12-12 19:34: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 {
|
||||
tenancy()->init($request->getHost());
|
||||
} catch (TenantCouldNotBeIdentifiedException $e) {
|
||||
($this->onFail)($e);
|
||||
return ($this->onFail)($e);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -41,7 +41,7 @@ class InitializeTenancyByRequestData
|
|||
try {
|
||||
$this->initializeTenancy($request);
|
||||
} catch (TenantCouldNotBeIdentifiedException $e) {
|
||||
($this->onFail)($e);
|
||||
return ($this->onFail)($e);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue