Convert $casts property to method

This commit is contained in:
Shift
2024-04-05 18:36:51 +00:00
parent 6295ded597
commit 5daad9303d

View File

@@ -47,14 +47,17 @@ class User extends Authenticatable implements FilamentUser
]; ];
/** /**
* The attributes that should be cast. * Get the attributes that should be cast.
* *
* @var array<string, string> * @return array<string, string>
*/ */
protected $casts = [ protected function casts(): array
'email_verified_at' => 'datetime', {
'password' => 'hashed', return [
]; 'email_verified_at' => 'datetime',
'password' => 'hashed',
];
}
public function canAccessPanel(Panel $panel): bool public function canAccessPanel(Panel $panel): bool
{ {