From 986e91b7d65323b68ef1d93330776476e9ca0613 Mon Sep 17 00:00:00 2001 From: astaxie Date: Mon, 18 Aug 2014 14:35:39 +0800 Subject: [PATCH] beego: update the debug info rules --- router.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/router.go b/router.go index 51b08235..dee96111 100644 --- a/router.go +++ b/router.go @@ -591,6 +591,7 @@ func (p *ControllerRegistor) ServeHTTP(rw http.ResponseWriter, r *http.Request) serverStaticRouter(context) if w.started { + findrouter = true goto Admin } @@ -769,9 +770,9 @@ Admin: if RunMode == "dev" { var devinfo string if findrouter { - devinfo = fmt.Sprintf("| % -10s| % -16s | % -10s | % -40s | % -10s | % -40s |", "beego", timeend.String(), r.Method, r.URL.Path, "match", routerInfo.pattern) + devinfo = fmt.Sprintf("| % -10s | % -40s | % -16s | % -10s | % -40s |", r.Method, r.URL.Path, timeend.String(), "match", routerInfo.pattern) } else { - devinfo = fmt.Sprintf("| % -10s| % -16s | % -10s | % -40s | % -10s |", "beego", timeend.String(), r.Method, r.URL.Path, "notmatch") + devinfo = fmt.Sprintf("| % -10s | % -40s | % -16s | % -10s |", r.Method, r.URL.Path, timeend.String(), "notmatch") } Debug(devinfo) }