Replies: 1 comment
-
Hello @Mendelski issue is in your select you add $fields but that variable not init in that code |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Laravel Version
10.45.1
PHP Version
8.2
Database Driver & Version
PgSQL
Description
i tryied to make a return on a route only for debug, using a function on api.php just like
is a little bigger, but only a query and a return.
and i have this error.
even if i try delete my new route, the error keep.
My solution is delete cache/route-v7 file and rebuild caches, and now works fine. (using a function inside controller)
Steps To Reproduce
a route like this
Route::get('/user', function (Request $request) {
$t = Transaction::query()->select($fields)->latest()->paginate(10);
return response()->json($t);
});
Beta Was this translation helpful? Give feedback.
All reactions