forked from forgejo/forgejo
API: Fix GetQueryBeforeSince (#13559)
This commit is contained in:
parent
374ff60465
commit
3f3447a1ea
5 changed files with 45 additions and 25 deletions
|
@ -57,7 +57,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"))
|
||||
|
@ -133,7 +133,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
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue