*/ use HasFactory, Notifiable; protected $fillable = [ 'name', 'username', 'email', 'password', 'is_active', 'must_change_pw', 'role', ]; protected $hidden = [ 'password', 'remember_token', ]; protected $casts = [ 'email_verified_at' => 'datetime', 'is_active' => 'boolean', 'must_change_pw' => 'boolean', ]; /** Quick helper: check if user is admin */ public function isAdmin(): bool { return $this->role === 'admin'; } }