summaryrefslogtreecommitdiffstats
path: root/modules
diff options
context:
space:
mode:
authorslene <vslene@gmail.com>2014-05-25 20:16:11 +0800
committerslene <vslene@gmail.com>2014-05-28 14:01:41 +0800
commit4ee6bc4fcac47edeea1f1e9fd5fbfd3ef595bbca (patch)
tree8867be03be123ea8c84bc92d7d388f6ac85de058 /modules
parentab13a29cb530457328cf9d3a2511c2db1d5ccaca (diff)
downloadgitea-4ee6bc4fcac47edeea1f1e9fd5fbfd3ef595bbca.tar.gz
gitea-4ee6bc4fcac47edeea1f1e9fd5fbfd3ef595bbca.zip
fix for new git api
Diffstat (limited to 'modules')
-rw-r--r--modules/base/tool.go3
1 files changed, 1 insertions, 2 deletions
diff --git a/modules/base/tool.go b/modules/base/tool.go
index a8bad9de3b..5b066b2b9f 100644
--- a/modules/base/tool.go
+++ b/modules/base/tool.go
@@ -509,8 +509,7 @@ type argInt []int
func (a argInt) Get(i int, args ...int) (r int) {
if i >= 0 && i < len(a) {
r = a[i]
- }
- if len(args) > 0 {
+ } else if len(args) > 0 {
r = args[0]
}
return