mirror of
https://github.com/filamentphp/filament.git
synced 2026-09-24 15:42:09 +08:00
fix phpstan
This commit is contained in:
@@ -46,17 +46,8 @@ class Export extends Model
|
||||
|
||||
$authenticatable = app(Authenticatable::class);
|
||||
|
||||
if ($authenticatable) {
|
||||
/** @phpstan-ignore-next-line */
|
||||
return $this->belongsTo($authenticatable::class);
|
||||
}
|
||||
|
||||
if (! class_exists(User::class)) {
|
||||
throw new Exception('No [App\\Models\\User] model found. Please bind an authenticatable model to the [Illuminate\\Contracts\\Auth\\Authenticatable] interface in a service provider\'s [register()] method.');
|
||||
}
|
||||
|
||||
/** @phpstan-ignore-next-line */
|
||||
return $this->belongsTo(User::class);
|
||||
return $this->belongsTo($authenticatable::class);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -52,17 +52,8 @@ class Import extends Model
|
||||
|
||||
$authenticatable = app(Authenticatable::class);
|
||||
|
||||
if ($authenticatable) {
|
||||
/** @phpstan-ignore-next-line */
|
||||
return $this->belongsTo($authenticatable::class);
|
||||
}
|
||||
|
||||
if (! class_exists(User::class)) {
|
||||
throw new Exception('No [App\\Models\\User] model found. Please bind an authenticatable model to the [Illuminate\\Contracts\\Auth\\Authenticatable] interface in a service provider\'s [register()] method.');
|
||||
}
|
||||
|
||||
/** @phpstan-ignore-next-line */
|
||||
return $this->belongsTo(User::class);
|
||||
return $this->belongsTo($authenticatable::class);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user