@@ -174,20 +174,20 @@ func SignInPost(ctx *context.Context, form auth.SignInForm) {
174
174
if err != nil {
175
175
if models .IsErrUserNotExist (err ) {
176
176
ctx .RenderWithErr (ctx .Tr ("form.username_password_incorrect" ), tplSignIn , & form )
177
- log .Info ("Failed authentication attempt for %s from %s" , form .UserName , ctx .RemoteAddr ())
177
+ log .Info ("Failed authentication attempt for %s from %s: %v " , form .UserName , ctx .RemoteAddr (), err )
178
178
} else if models .IsErrEmailAlreadyUsed (err ) {
179
179
ctx .RenderWithErr (ctx .Tr ("form.email_been_used" ), tplSignIn , & form )
180
- log .Info ("Failed authentication attempt for %s from %s" , form .UserName , ctx .RemoteAddr ())
180
+ log .Info ("Failed authentication attempt for %s from %s: %v " , form .UserName , ctx .RemoteAddr (), err )
181
181
} else if models .IsErrUserProhibitLogin (err ) {
182
- log .Info ("Failed authentication attempt for %s from %s" , form .UserName , ctx .RemoteAddr ())
182
+ log .Info ("Failed authentication attempt for %s from %s: %v " , form .UserName , ctx .RemoteAddr (), err )
183
183
ctx .Data ["Title" ] = ctx .Tr ("auth.prohibit_login" )
184
184
ctx .HTML (200 , "user/auth/prohibit_login" )
185
185
} else if models .IsErrUserInactive (err ) {
186
186
if setting .Service .RegisterEmailConfirm {
187
187
ctx .Data ["Title" ] = ctx .Tr ("auth.active_your_account" )
188
188
ctx .HTML (200 , TplActivate )
189
189
} else {
190
- log .Info ("Failed authentication attempt for %s from %s" , form .UserName , ctx .RemoteAddr ())
190
+ log .Info ("Failed authentication attempt for %s from %s: %v " , form .UserName , ctx .RemoteAddr (), err )
191
191
ctx .Data ["Title" ] = ctx .Tr ("auth.prohibit_login" )
192
192
ctx .HTML (200 , "user/auth/prohibit_login" )
193
193
}
0 commit comments