mirror of
https://github.com/archtechx/tenancy.git
synced 2026-02-05 11:44:04 +00:00
Remove request from tenant manager
This commit is contained in:
parent
cacf239801
commit
cfa9514dfb
2 changed files with 2 additions and 3 deletions
|
|
@ -29,7 +29,7 @@ class InitializeTenancy
|
|||
public function handle($request, Closure $next)
|
||||
{
|
||||
try {
|
||||
tenancy()->init();
|
||||
tenancy()->init($request->getHost());
|
||||
} catch (TenantCouldNotBeIdentifiedException $e) {
|
||||
($this->onFail)($e);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -133,9 +133,8 @@ class TenantManager
|
|||
* @param string $domain
|
||||
* @return self
|
||||
*/
|
||||
public function init(string $domain = null): self
|
||||
public function init(string $domain): self
|
||||
{
|
||||
$domain = $domain ?? request()->getHost();
|
||||
$this->initializeTenancy($this->findByDomain($domain));
|
||||
|
||||
return $this;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue