input("all") == true) { if(!Auth::check()) { throw new NotLoggedInException(); } if(!Auth::user()->admin) { throw new NoPermissionException(); } $settings = Setting::all(); } return $response->withData(\App\Http\Resources\API\Setting::collection(collect($settings))); } }