Skip to content

Commit

Permalink
routes update
Browse files Browse the repository at this point in the history
  • Loading branch information
gqcn committed Sep 14, 2019
1 parent 4ca0320 commit cf2ad9a
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 11 deletions.
4 changes: 2 additions & 2 deletions app/service/document/document.go
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,9 @@ func UpdateDocGit() {
// 每次文档的更新都要清除缓存对象数据
cache.Clear()

glog.Cat("doc-hook").Printfln("doc hook updates")
glog.Cat("doc-hook").Printf("doc hook updates")
} else {
glog.Cat("doc-hook").Printfln("doc hook updates error: %v", err)
glog.Cat("doc-hook").Printf("doc hook updates error: %v", err)
}
}

Expand Down
12 changes: 6 additions & 6 deletions router/cli.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,15 @@ import (

func init() {
g.Server().Group("/cli", func(g *ghttp.RouterGroup) {
g.GET("/*path", binary.Index)
g.GET("/version", version.Latest)
g.ALL("/*path", binary.Index)
g.ALL("/version", version.Latest)
g.Group("/binary", func(g *ghttp.RouterGroup) {
g.GET("/*path", binary.Index)
g.GET("/md5", binary.Md5)
g.ALL("/*path", binary.Index)
g.ALL("/md5", binary.Md5)
})
g.Group("/project", func(g *ghttp.RouterGroup) {
g.GET("/md5", project.Md5)
g.GET("/zip", project.Zip)
g.ALL("/md5", project.Md5)
g.ALL("/zip", project.Zip)
})
})
}
6 changes: 3 additions & 3 deletions router/document.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ import (

func init() {
g.Server().Group("/", func(g *ghttp.RouterGroup) {
g.GET("/*path", document.Index)
g.GET("/hook", document.UpdateHook)
g.GET("/search", document.Search)
g.ALL("/*path", document.Index)
g.ALL("/hook", document.UpdateHook)
g.ALL("/search", document.Search)
})
}

0 comments on commit cf2ad9a

Please sign in to comment.