diff options
Diffstat (limited to 'routers/api/v1/user/star.go')
-rw-r--r-- | routers/api/v1/user/star.go | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/routers/api/v1/user/star.go b/routers/api/v1/user/star.go index 14bc23b1c3..cc527d9213 100644 --- a/routers/api/v1/user/star.go +++ b/routers/api/v1/user/star.go @@ -67,7 +67,10 @@ func GetStarredRepos(ctx *context.APIContext) { repos, err := getStarredRepos(user, private, utils.GetListOptions(ctx)) if err != nil { ctx.Error(http.StatusInternalServerError, "getStarredRepos", err) + return } + + ctx.SetTotalCountHeader(int64(user.NumStars)) ctx.JSON(http.StatusOK, &repos) } |