aboutsummaryrefslogtreecommitdiff
path: root/pkg/context/api.go
diff options
context:
space:
mode:
authorUnknwon <u@gogs.io>2018-12-02 12:55:05 -0500
committerUnknwon <u@gogs.io>2018-12-02 12:55:05 -0500
commite1b3a250085195122c3b41b998504692f47fcb63 (patch)
tree40614fe982572c95f401af688c7d4d1617921ae8 /pkg/context/api.go
parent69c1cd3f381b19b988a6af51a8e38303f216b001 (diff)
api/repo: support edit repository issue tracker (gogs/go-gogs-client#94)
Diffstat (limited to 'pkg/context/api.go')
-rw-r--r--pkg/context/api.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/pkg/context/api.go b/pkg/context/api.go
index 7df5b23a..439fb5df 100644
--- a/pkg/context/api.go
+++ b/pkg/context/api.go
@@ -44,6 +44,11 @@ func (c *APIContext) Error(status int, title string, obj interface{}) {
})
}
+// NoContent renders the 204 response.
+func (c *APIContext) NoContent() {
+ c.Status(http.StatusNoContent)
+}
+
// NotFound renders the 404 response.
func (c *APIContext) NotFound() {
c.Status(http.StatusNotFound)