1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28
<?php namespace App\Models; use Illuminate\Foundation\Auth\User as Authenticatable; class Player extends Authenticatable { protected $fillable = [ 'name', 'password', 'team', 'score', ]; protected $hidden = [ 'password', 'remember_token', 'is_amdin', ]; protected function casts(): array { return [ 'password' => 'hashed', ]; } }