mirror of
https://github.com/yusing/godoxy.git
synced 2026-04-24 09:48:49 +02:00
fix(oidc): incorrect redirect url
This commit is contained in:
@@ -53,7 +53,7 @@ func RequireAuth(next http.HandlerFunc) http.HandlerFunc {
|
|||||||
|
|
||||||
func AuthCheckHandler(w http.ResponseWriter, r *http.Request) {
|
func AuthCheckHandler(w http.ResponseWriter, r *http.Request) {
|
||||||
if err := defaultAuth.CheckToken(r); err != nil {
|
if err := defaultAuth.CheckToken(r); err != nil {
|
||||||
http.Redirect(w, r, "/v1/auth/login", http.StatusFound)
|
defaultAuth.LoginHandler(w, r)
|
||||||
} else {
|
} else {
|
||||||
w.WriteHeader(http.StatusOK)
|
w.WriteHeader(http.StatusOK)
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user