IP: RC Code Review
This commit is contained in:
parent
c796ed3849
commit
f470c241d6
9 changed files with 28 additions and 32 deletions
8
web.go
8
web.go
|
@ -138,6 +138,10 @@ func runWeb(*cli.Context) {
|
|||
r.Any("/:userid/delete", admin.DeleteUser)
|
||||
}, adminReq)
|
||||
|
||||
if martini.Env == martini.Dev {
|
||||
m.Get("/template/**", dev.TemplatePreview)
|
||||
}
|
||||
|
||||
m.Group("/:username/:reponame", func(r martini.Router) {
|
||||
r.Post("/settings", repo.SettingPost)
|
||||
r.Get("/settings", repo.Setting)
|
||||
|
@ -168,10 +172,6 @@ func runWeb(*cli.Context) {
|
|||
r.Any("/:reponame/**", repo.Http)
|
||||
}, ignSignIn)
|
||||
|
||||
if martini.Env == martini.Dev {
|
||||
m.Get("/template/**", dev.TemplatePreview)
|
||||
}
|
||||
|
||||
// Not found handler.
|
||||
m.NotFound(routers.NotFound)
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue