Browse Source

fix #751

for-closed-social
Unknwon 10 years ago
parent
commit
d01f2f3c22
1 changed files with 9 additions and 0 deletions
  1. +9
    -0
      routers/user/home.go

+ 9
- 0
routers/user/home.go View File

@ -198,6 +198,15 @@ func Profile(ctx *middleware.Context) {
}
feeds := make([]*models.Action, 0, len(actions))
for _, act := range actions {
if act.IsPrivate {
if !ctx.IsSigned {
continue
}
if has, _ := models.HasAccess(ctx.User.Name, act.RepoUserName+"/"+act.RepoName,
models.READABLE); !has {
continue
}
}
// FIXME: cache results?
u, err := models.GetUserByName(act.ActUserName)
if err != nil {

Loading…
Cancel
Save