1
0
Fork 0
forked from forgejo/forgejo

#842 able to use access token replace basic auth

This commit is contained in:
Unknwon 2015-09-02 02:40:15 -04:00
parent ebf1bd4f51
commit 2ac8e11f46
7 changed files with 53 additions and 32 deletions

View file

@ -211,7 +211,7 @@ func Contexter() macaron.Handler {
}
// Get user from session if logined.
ctx.User, ctx.IsBasicAuth = auth.SignedInUser(ctx.Req.Request, ctx.Session)
ctx.User, ctx.IsBasicAuth = auth.SignedInUser(ctx.Context, ctx.Session)
if ctx.User != nil {
ctx.IsSigned = true