1
0
mirror of https://github.com/astaxie/beego.git synced 2024-11-25 20:00:55 +00:00

fix the range only used in Go 1.4 fix #1623

This commit is contained in:
astaxie 2016-01-25 21:39:44 +08:00
parent f8004b69ad
commit 15e9ba19c0

View File

@ -141,7 +141,7 @@ func (t *Tree) addtree(segments []string, tree *Tree, wildcards []string, reg st
regexpStr = "([^.]+).(.+)"
params = params[1:]
} else {
for range params {
for _ = range params {
regexpStr = "([^/]+)/" + regexpStr
}
}
@ -254,7 +254,7 @@ func (t *Tree) addseg(segments []string, route interface{}, wildcards []string,
regexpStr = "/([^.]+).(.+)"
params = params[1:]
} else {
for range params {
for _ = range params {
regexpStr = "/([^/]+)" + regexpStr
}
}