Browse Source

Fix #165

tags/v1.2.0-rc1
Unknown 11 years ago
parent
commit
9d2cef23f2
1 changed files with 5 additions and 1 deletions
  1. +5
    -1
      modules/auth/user.go

+ 5
- 1
modules/auth/user.go View File

@@ -25,7 +25,11 @@ func SignedInId(header http.Header, sess session.SessionStore) int64 {
return 0
}

id, _ := base.StrTo(header.Get(setting.ReverseProxyAuthUid)).Int64()
var id int64
if setting.Service.EnableReverseProxyAuth {
id, _ = base.StrTo(header.Get(setting.ReverseProxyAuthUid)).Int64()
}

if id <= 0 {
uid := sess.Get("userId")
if uid == nil {


Loading…
Cancel
Save