aboutsummaryrefslogtreecommitdiff
path: root/web.go
diff options
context:
space:
mode:
authorLunny Xiao <xiaolunwen@gmail.com>2014-03-28 10:51:42 +0800
committerLunny Xiao <xiaolunwen@gmail.com>2014-03-28 10:51:42 +0800
commit89258e868b070ff3046de912e1d9a3009f923b62 (patch)
tree96d582c68daf862d0328e0734ede3da88e308fb8 /web.go
parent922a189f4061796b0d4afeeb45e508c36cc5e7fc (diff)
parent5344a0300383c4921e4a5810dff58c7686412f0c (diff)
Merge branch 'master' of github.com:gogits/gogs
Diffstat (limited to 'web.go')
-rw-r--r--web.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/web.go b/web.go
index 3c7abc58..4ed273ea 100644
--- a/web.go
+++ b/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)