mirror of
https://github.com/goharbor/harbor.git
synced 2024-11-26 04:05:40 +01:00
Merge pull request #17 from reasonerjt/master
Login fail in ldap should return 401
This commit is contained in:
commit
d8992aa8ed
@ -53,7 +53,7 @@ func (c *CommonController) Login() {
|
|||||||
user, err := auth.Login(models.AuthModel{principal, password})
|
user, err := auth.Login(models.AuthModel{principal, password})
|
||||||
if err != nil {
|
if err != nil {
|
||||||
beego.Error("Error occurred in UserLogin:", err)
|
beego.Error("Error occurred in UserLogin:", err)
|
||||||
c.CustomAbort(http.StatusInternalServerError, "Internal error.")
|
c.CustomAbort(http.StatusUnauthorized, "")
|
||||||
}
|
}
|
||||||
|
|
||||||
if user == nil {
|
if user == nil {
|
||||||
|
Loading…
Reference in New Issue
Block a user