@@ -37,7 +37,7 @@ public function __construct(User $model)
3737 /**
3838 * @return mixed
3939 */
40- public function getUnconfirmedCount () : int
40+ public function getUnconfirmedCount (): int
4141 {
4242 return $ this ->model
4343 ->where ('confirmed ' , false )
@@ -51,7 +51,7 @@ public function getUnconfirmedCount() : int
5151 *
5252 * @return mixed
5353 */
54- public function getActivePaginated ($ paged = 25 , $ orderBy = 'created_at ' , $ sort = 'desc ' ) : LengthAwarePaginator
54+ public function getActivePaginated ($ paged = 25 , $ orderBy = 'created_at ' , $ sort = 'desc ' ): LengthAwarePaginator
5555 {
5656 return $ this ->model
5757 ->with ('roles ' , 'permissions ' , 'providers ' )
@@ -67,7 +67,7 @@ public function getActivePaginated($paged = 25, $orderBy = 'created_at', $sort =
6767 *
6868 * @return LengthAwarePaginator
6969 */
70- public function getInactivePaginated ($ paged = 25 , $ orderBy = 'created_at ' , $ sort = 'desc ' ) : LengthAwarePaginator
70+ public function getInactivePaginated ($ paged = 25 , $ orderBy = 'created_at ' , $ sort = 'desc ' ): LengthAwarePaginator
7171 {
7272 return $ this ->model
7373 ->with ('roles ' , 'permissions ' , 'providers ' )
@@ -83,7 +83,7 @@ public function getInactivePaginated($paged = 25, $orderBy = 'created_at', $sort
8383 *
8484 * @return LengthAwarePaginator
8585 */
86- public function getDeletedPaginated ($ paged = 25 , $ orderBy = 'created_at ' , $ sort = 'desc ' ) : LengthAwarePaginator
86+ public function getDeletedPaginated ($ paged = 25 , $ orderBy = 'created_at ' , $ sort = 'desc ' ): LengthAwarePaginator
8787 {
8888 return $ this ->model
8989 ->with ('roles ' , 'permissions ' , 'providers ' )
@@ -99,7 +99,7 @@ public function getDeletedPaginated($paged = 25, $orderBy = 'created_at', $sort
9999 * @throws \Throwable
100100 * @return User
101101 */
102- public function create (array $ data ) : User
102+ public function create (array $ data ): User
103103 {
104104 return DB ::transaction (function () use ($ data ) {
105105 $ user = $ this ->model ::create ([
@@ -150,7 +150,7 @@ public function create(array $data) : User
150150 * @throws \Throwable
151151 * @return User
152152 */
153- public function update (User $ user , array $ data ) : User
153+ public function update (User $ user , array $ data ): User
154154 {
155155 $ this ->checkUserByEmail ($ user , $ data ['email ' ]);
156156
@@ -185,7 +185,7 @@ public function update(User $user, array $data) : User
185185 * @throws GeneralException
186186 * @return User
187187 */
188- public function updatePassword (User $ user , $ input ) : User
188+ public function updatePassword (User $ user , $ input ): User
189189 {
190190 if ($ user ->update (['password ' => $ input ['password ' ]])) {
191191 event (new UserPasswordChanged ($ user ));
@@ -203,7 +203,7 @@ public function updatePassword(User $user, $input) : User
203203 * @throws GeneralException
204204 * @return User
205205 */
206- public function mark (User $ user , $ status ) : User
206+ public function mark (User $ user , $ status ): User
207207 {
208208 if ($ status === 0 && auth ()->id () === $ user ->id ) {
209209 throw new GeneralException (__ ('exceptions.backend.access.users.cant_deactivate_self ' ));
@@ -233,7 +233,7 @@ public function mark(User $user, $status) : User
233233 * @throws GeneralException
234234 * @return User
235235 */
236- public function confirm (User $ user ) : User
236+ public function confirm (User $ user ): User
237237 {
238238 if ($ user ->confirmed ) {
239239 throw new GeneralException (__ ('exceptions.backend.access.users.already_confirmed ' ));
@@ -262,7 +262,7 @@ public function confirm(User $user) : User
262262 * @throws GeneralException
263263 * @return User
264264 */
265- public function unconfirm (User $ user ) : User
265+ public function unconfirm (User $ user ): User
266266 {
267267 if (! $ user ->confirmed ) {
268268 throw new GeneralException (__ ('exceptions.backend.access.users.not_confirmed ' ));
@@ -298,7 +298,7 @@ public function unconfirm(User $user) : User
298298 * @throws \Throwable
299299 * @return User
300300 */
301- public function forceDelete (User $ user ) : User
301+ public function forceDelete (User $ user ): User
302302 {
303303 if ($ user ->deleted_at === null ) {
304304 throw new GeneralException (__ ('exceptions.backend.access.users.delete_first ' ));
@@ -325,7 +325,7 @@ public function forceDelete(User $user) : User
325325 * @throws GeneralException
326326 * @return User
327327 */
328- public function restore (User $ user ) : User
328+ public function restore (User $ user ): User
329329 {
330330 if ($ user ->deleted_at === null ) {
331331 throw new GeneralException (__ ('exceptions.backend.access.users.cant_restore ' ));
0 commit comments