diff options
Diffstat (limited to 'routers/api/v1/user/follower.go')
-rw-r--r-- | routers/api/v1/user/follower.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/routers/api/v1/user/follower.go b/routers/api/v1/user/follower.go index 4d316425cd..e273ac6a02 100644 --- a/routers/api/v1/user/follower.go +++ b/routers/api/v1/user/follower.go @@ -29,6 +29,8 @@ func listUserFollowers(ctx *context.APIContext, u *models.User) { ctx.Error(http.StatusInternalServerError, "GetUserFollowers", err) return } + + ctx.SetTotalCountHeader(int64(u.NumFollowers)) responseAPIUsers(ctx, users) } @@ -93,6 +95,8 @@ func listUserFollowing(ctx *context.APIContext, u *models.User) { ctx.Error(http.StatusInternalServerError, "GetFollowing", err) return } + + ctx.SetTotalCountHeader(int64(u.NumFollowing)) responseAPIUsers(ctx, users) } |