1 | <?php |
||
42 | class User extends \Eloquent implements |
||
43 | AuthenticatableContract, |
||
44 | AuthorizableContract, |
||
45 | CanResetPasswordContract |
||
46 | { |
||
47 | use Authenticatable, |
||
48 | Authorizable, |
||
49 | CanResetPassword, |
||
50 | |||
51 | // Gitter converter |
||
52 | UserMapperTrait; |
||
53 | |||
54 | /** |
||
55 | * @var string |
||
56 | */ |
||
57 | protected $table = 'users'; |
||
58 | |||
59 | /** |
||
60 | * @var array |
||
61 | */ |
||
62 | protected $hidden = ['password', 'remember_token']; |
||
63 | |||
64 | /** |
||
65 | * @var array |
||
66 | */ |
||
67 | protected $fillable = ['gitter_id', 'url', 'login', 'name', 'avatar']; |
||
68 | |||
69 | /** |
||
70 | * |
||
71 | */ |
||
72 | protected static function boot() |
||
76 | |||
77 | /** |
||
78 | * @return \Illuminate\Database\Eloquent\Relations\HasMany |
||
79 | */ |
||
80 | public function achievements() |
||
84 | |||
85 | /** |
||
86 | * @return \Illuminate\Database\Eloquent\Relations\BelongsTo |
||
87 | */ |
||
88 | public function karma() |
||
92 | |||
93 | /** |
||
94 | * @return string |
||
95 | */ |
||
96 | public function getKarmaTextAttribute() |
||
102 | |||
103 | /** |
||
104 | * @return \Illuminate\Database\Eloquent\Relations\BelongsTo |
||
105 | */ |
||
106 | public function thanks() |
||
110 | |||
111 | /** |
||
112 | * @return string |
||
113 | */ |
||
114 | public function getThanksTextAttribute() |
||
118 | |||
119 | /** |
||
120 | * @param $roomId |
||
121 | * @return Carbon |
||
122 | */ |
||
123 | public function getLastKarmaTimeForRoom($roomId) |
||
137 | |||
138 | /** |
||
139 | * @param User $user |
||
140 | * @param Message $message |
||
141 | * @return static |
||
142 | */ |
||
143 | public function addKarmaTo(User $user, Message $message) |
||
153 | } |
||
154 |
Methods can only be called on objects. This check looks for methods being called on variables that have been inferred to never be objects.