Commit 2f754455 authored by astaxie's avatar astaxie

when runmode is dev it will show warning ingo

if have a attack url, the info is
parent 43057a2f
......@@ -461,7 +461,9 @@ func (p *ControllerRegistor) ServeHTTP(rw http.ResponseWriter, r *http.Request)
file := staticDir + r.URL.Path[len(prefix):]
finfo, err := os.Stat(file)
if err != nil {
Warn(err)
if RunMode == "dev" {
Warn(err)
}
http.NotFound(w, r)
return
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment