Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Routes referencing incorrect Controller method #1

Open
jbped opened this issue Feb 24, 2022 · 0 comments · May be fixed by #4
Open

Routes referencing incorrect Controller method #1

jbped opened this issue Feb 24, 2022 · 0 comments · May be fixed by #4
Labels
bug Something isn't working

Comments

@jbped
Copy link
Collaborator

jbped commented Feb 24, 2022

Description:

The GET /friends route is utilizing a non-existent method (getFriends).

Location:

/routes/web.php line 44
Route::get('/friends', [UserController::class, 'getFriends'])->name('user.getFriends');

Discovery:

When reviewing the UserController I found that there was no getFriends method, however there was a getUserConnections method that appears to fit the use case.

Proposed Solution:

Edit /routes/web.php line 44
FROM:
Route::get('/friends', [UserController::class, 'getFriends'])->name('user.getFriends');
TO:
Route::get('/friends', [UserController::class, 'getUserConnections'])->name('user.getFriends');

@jbped jbped added the bug Something isn't working label Feb 24, 2022
@jbped jbped linked a pull request Mar 2, 2022 that will close this issue
@jbped jbped changed the title GET /friends referencing UserController incorrect method Routes referencing incorrect Controller method Mar 2, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant