Merge pull request 'Handle 201 when ensuring ticket is open' (#62) from update-fix into main
Reviewed-on: https://git.ts.mattnite.net/mattnite/forgejo-tickets/pulls/62
This commit is contained in:
commit
0f4286032d
|
|
@ -636,7 +636,7 @@ func (c *Client) EditIssue(owner, repo string, number int64, req EditIssueReques
|
|||
}
|
||||
defer resp.Body.Close()
|
||||
|
||||
if resp.StatusCode != http.StatusOK {
|
||||
if resp.StatusCode != http.StatusOK && resp.StatusCode != http.StatusCreated {
|
||||
respBody, _ := io.ReadAll(resp.Body)
|
||||
return fmt.Errorf("forgejo API returned %d: %s", resp.StatusCode, string(respBody))
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue