mirror of
https://github.com/archtechx/tenancy.git
synced 2025-12-13 04:04:04 +00:00
resolve all phpstan issues
This commit is contained in:
parent
b7a6953231
commit
942d79cbd7
12 changed files with 57 additions and 88 deletions
|
|
@ -42,8 +42,7 @@ class Tenancy
|
|||
}
|
||||
}
|
||||
|
||||
// todo1 for phpstan this should be $this->tenant?, but first I want to clean up the $initialized logic and explore removing the property
|
||||
if ($this->initialized && $this->tenant->getTenantKey() === $tenant->getTenantKey()) {
|
||||
if ($this->initialized && $this->tenant?->getTenantKey() === $tenant->getTenantKey()) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
@ -52,6 +51,7 @@ class Tenancy
|
|||
$this->end();
|
||||
}
|
||||
|
||||
/** @var Tenant&Model $tenant */
|
||||
$this->tenant = $tenant;
|
||||
|
||||
event(new Events\InitializingTenancy($this));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue