mirror of
https://github.com/ClusterCockpit/cc-backend
synced 2025-07-25 13:46:07 +02:00
fix: oversight error on redirect target
This commit is contained in:
@@ -240,9 +240,10 @@ func (auth *Authentication) Login(
|
|||||||
|
|
||||||
if r.FormValue("redirect") != "" {
|
if r.FormValue("redirect") != "" {
|
||||||
http.RedirectHandler(r.FormValue("redirect"), http.StatusFound).ServeHTTP(rw, r.WithContext(ctx))
|
http.RedirectHandler(r.FormValue("redirect"), http.StatusFound).ServeHTTP(rw, r.WithContext(ctx))
|
||||||
} else {
|
return
|
||||||
http.RedirectHandler(r.FormValue("/"), http.StatusFound).ServeHTTP(rw, r.WithContext(ctx))
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
http.RedirectHandler("/", http.StatusFound).ServeHTTP(rw, r.WithContext(ctx))
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user