In the scaffolded actions/users.go, middleware SetCurrentUser just returned a general error which causes a 404 error. However, it could be better if the middleware generates Unauthorized or just redirects users to the login page. With this change, the middleware redirects the user to the login page.
What is being done in this PR?
In the scaffolded
actions/users.go
, middlewareSetCurrentUser
just returned a general error which causes a404
error. However, it could be better if the middleware generatesUnauthorized
or just redirects users to the login page. With this change, the middleware redirects the user to the login page.fixes #30
see also: https://github.com/gobuffalo/buffalo-auth/issues/30#issuecomment-1416676908
What are the main choices made to get to this solution?
List the manual test cases you've covered before sending this PR: