Browse Source

Fix 500 in public activity page (#1901)

master
Ethan Koenig Bo-Yi Wu 8 years ago
parent
commit
afe1f1c4af
1 changed files with 5 additions and 1 deletions
  1. +5
    -1
      routers/user/home.go

+ 5
- 1
routers/user/home.go View File

@@ -55,9 +55,13 @@ func getDashboardContextUser(ctx *context.Context) *models.User {

// retrieveFeeds loads feeds for the specified user
func retrieveFeeds(ctx *context.Context, user *models.User, includePrivate, isProfile bool) {
var requestingID int64
if ctx.User != nil {
requestingID = ctx.User.ID
}
actions, err := models.GetFeeds(models.GetFeedsOptions{
RequestedUser: user,
RequestingUserID: ctx.User.ID,
RequestingUserID: requestingID,
IncludePrivate: includePrivate,
OnlyPerformedBy: isProfile,
})


Loading…
Cancel
Save