1 | <?php |
||
7 | class User extends Authenticatable |
||
8 | { |
||
9 | /** |
||
10 | * The attributes that are mass assignable. |
||
11 | * |
||
12 | * @var array |
||
13 | */ |
||
14 | protected $fillable = [ |
||
15 | 'fullname', 'username', 'email', 'password', 'provider_id', 'provider', |
||
16 | 'avatar', 'gender', 'location', 'website', 'oauth_token', 'oauth_token_secret' |
||
17 | ]; |
||
18 | |||
19 | /** |
||
20 | * The attributes excluded from the model's JSON form. |
||
21 | * |
||
22 | * @var array |
||
23 | */ |
||
24 | protected $hidden = [ |
||
25 | 'password', 'remember_token', |
||
26 | ]; |
||
27 | |||
28 | public function getAvatarUrl() |
||
36 | |||
37 | public function getAccessToken() |
||
41 | |||
42 | public function getAccessTokenSecret() |
||
46 | } |
||
47 |
Since your code implements the magic getter
_get
, this function will be called for any read access on an undefined variable. You can add the@property
annotation to your class or interface to document the existence of this variable.If the property has read access only, you can use the @property-read annotation instead.
Of course, you may also just have mistyped another name, in which case you should fix the error.
See also the PhpDoc documentation for @property.