From f1bbdc9e59771d135037a0a14dae2135e6745fe7 Mon Sep 17 00:00:00 2001 From: snipe Date: Tue, 23 Jan 2018 18:13:41 -0800 Subject: [PATCH] Revert PR #4845 --- app/Http/Controllers/Api/UsersController.php | 1 - 1 file changed, 1 deletion(-) diff --git a/app/Http/Controllers/Api/UsersController.php b/app/Http/Controllers/Api/UsersController.php index d611eaa770..f5b7ce08e4 100644 --- a/app/Http/Controllers/Api/UsersController.php +++ b/app/Http/Controllers/Api/UsersController.php @@ -286,7 +286,6 @@ class UsersController extends Controller { $this->authorize('view', User::class); $assets = Asset::where('assigned_to', '=', $id)->with('model')->get(); - if ($assets) $this->authorize('view', $assets[0]); return (new AssetsTransformer)->transformAssets($assets, $assets->count()); } }