ClearBowl/api/app/Models/User.php

29 lines
498 B
PHP
Raw Normal View History

<?php
namespace App\Models;
use Illuminate\Foundation\Auth\User as Authenticatable;
use Tymon\JWTAuth\Contracts\JWTSubject;
class User extends Authenticatable implements JWTSubject
{
2019-11-30 18:50:57 +01:00
protected $fillable = [
'email', 'password', 'role'
];
2019-11-30 18:54:49 +01:00
protected $hidden = [
'password', 'created_at', 'updated_at'
];
public function getJWTIdentifier()
{
return $this->getKey();
}
2019-11-30 18:50:57 +01:00
public function getJWTCustomClaims()
{
return [];
}
}