aboutsummaryrefslogtreecommitdiff
path: root/pkg/context/api.go
diff options
context:
space:
mode:
authorUnknwon <u@gogs.io>2017-04-05 09:17:21 -0400
committerUnknwon <u@gogs.io>2017-04-05 09:17:21 -0400
commitedaf14f2b6fd86f8dec99f67512a5c0095e391dc (patch)
treeec81011348a0c8df3995c36b46e2646472106800 /pkg/context/api.go
parent6fbb984ebf4f0d6804f0f83e6edb12ef0bb9a570 (diff)
Refactoring: remove tool.TplName
Diffstat (limited to 'pkg/context/api.go')
-rw-r--r--pkg/context/api.go6
1 files changed, 4 insertions, 2 deletions
diff --git a/pkg/context/api.go b/pkg/context/api.go
index 5e29a73f..ffaddd33 100644
--- a/pkg/context/api.go
+++ b/pkg/context/api.go
@@ -12,7 +12,6 @@ import (
log "gopkg.in/clog.v1"
"gopkg.in/macaron.v1"
- "github.com/gogits/gogs/pkg/tool"
"github.com/gogits/gogs/pkg/setting"
)
@@ -21,6 +20,9 @@ type APIContext struct {
Org *APIOrganization
}
+// FIXME: move to github.com/gogits/go-gogs-client
+const DOC_URL = "https://github.com/gogits/go-gogs-client/wiki"
+
// Error responses error message to client with given message.
// If status is 500, also it prints error to log.
func (ctx *APIContext) Error(status int, title string, obj interface{}) {
@@ -37,7 +39,7 @@ func (ctx *APIContext) Error(status int, title string, obj interface{}) {
ctx.JSON(status, map[string]string{
"message": message,
- "url": tool.DOC_URL,
+ "url": DOC_URL,
})
}