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

get phpstan errors down from 252 to 189

This commit is contained in:
Samuel Štancl 2022-08-30 05:44:23 +02:00
parent fb8b9c1614
commit 8af354c20e
40 changed files with 119 additions and 115 deletions

View file

@ -10,12 +10,12 @@ use Illuminate\Support\Str;
use Stancl\Tenancy\Database\Concerns\CentralConnection;
/**
* @param string $token
* @param string $tenant_id
* @param string $user_id
* @param string $auth_guard
* @param string $redirect_url
* @param Carbon $created_at
* @property string $token
* @property string $tenant_id
* @property string $user_id
* @property string $auth_guard
* @property string $redirect_url
* @property Carbon $created_at
*/
class ImpersonationToken extends Model
{
@ -35,7 +35,7 @@ class ImpersonationToken extends Model
'created_at',
];
public static function booted()
public static function booted(): void
{
static::creating(function ($model) {
$model->created_at = $model->created_at ?? $model->freshTimestamp();