Ken 5 dias atrás
pai
commit
127a5c07cf
1 arquivos alterados com 2 adições e 1 exclusões
  1. 2 1
      app/Http/Controllers/admin/User.php

+ 2 - 1
app/Http/Controllers/admin/User.php

@@ -53,6 +53,7 @@ class User extends Controller
     public function index(): JsonResponse
     {
         try {
+            $_GET['page'] = 3;
             $search = request()->validate([
                 'page' => ['nullable', 'integer', 'min:1'],
                 'limit' => ['nullable', 'integer', 'min:1'],
@@ -60,7 +61,7 @@ class User extends Controller
                 'first_name' => ['nullable', 'string', 'min:1'],
                 'username' => ['nullable', 'string', 'min:1'],
             ]);
-            $_GET['page'] = 3;
+
             $result = UserService::paginate($search);
         } catch (ValidationException $e) {
             return $this->error(HttpStatus::CUSTOM_ERROR, $e->validator->errors()->first());