diff options
Diffstat (limited to 'modules/context/permission.go')
-rw-r--r-- | modules/context/permission.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/context/permission.go b/modules/context/permission.go index 2b87aa4591..142b86faea 100644 --- a/modules/context/permission.go +++ b/modules/context/permission.go @@ -49,7 +49,7 @@ func RequireRepoReader(unitType unit.Type) func(ctx *Context) { if ctx.IsSigned { log.Trace("Permission Denied: User %-v cannot read %-v in Repo %-v\n"+ "User in Repo has Permissions: %-+v", - ctx.User, + ctx.Doer, unitType, ctx.Repo.Repository, ctx.Repo.Permission) @@ -80,7 +80,7 @@ func RequireRepoReaderOr(unitTypes ...unit.Type) func(ctx *Context) { var args []interface{} if ctx.IsSigned { format = "Permission Denied: User %-v cannot read [" - args = append(args, ctx.User) + args = append(args, ctx.Doer) } else { format = "Permission Denied: Anonymous user cannot read [" } |