1
1
mirror of https://github.com/go-gitea/gitea synced 2025-08-24 10:28:27 +00:00

API: Fix GetQueryBeforeSince (#13561)

This commit is contained in:
6543
2020-11-19 03:21:21 +01:00
committed by GitHub
parent bcde51f4c2
commit 2f6dad2e34
5 changed files with 45 additions and 25 deletions

View File

@@ -56,7 +56,7 @@ func ListIssueComments(ctx *context.APIContext) {
before, since, err := utils.GetQueryBeforeSince(ctx)
if err != nil {
ctx.Error(http.StatusInternalServerError, "GetQueryBeforeSince", err)
ctx.Error(http.StatusUnprocessableEntity, "GetQueryBeforeSince", err)
return
}
issue, err := models.GetIssueByIndex(ctx.Repo.Repository.ID, ctx.ParamsInt64(":index"))
@@ -132,7 +132,7 @@ func ListRepoIssueComments(ctx *context.APIContext) {
before, since, err := utils.GetQueryBeforeSince(ctx)
if err != nil {
ctx.Error(http.StatusInternalServerError, "GetQueryBeforeSince", err)
ctx.Error(http.StatusUnprocessableEntity, "GetQueryBeforeSince", err)
return
}