mirror of
https://github.com/astaxie/beego.git
synced 2025-07-03 02:30:19 +00:00
make golint happy and also make the config readable
This commit is contained in:
@ -617,7 +617,7 @@ func (p *ControllerRegister) ServeHTTP(rw http.ResponseWriter, r *http.Request)
|
||||
if ok, params := filterR.ValidRouter(urlPath); ok {
|
||||
for k, v := range params {
|
||||
if context.Input.Params == nil {
|
||||
context.Input.Params = make(map[string]string)
|
||||
context.Input.Params = make(map[string]string)
|
||||
}
|
||||
context.Input.Params[k] = v
|
||||
}
|
||||
@ -869,7 +869,7 @@ func (p *ControllerRegister) recoverPanic(context *beecontext.Context) {
|
||||
if !RecoverPanic {
|
||||
panic(err)
|
||||
} else {
|
||||
if ErrorsShow {
|
||||
if EnableErrorsShow {
|
||||
if _, ok := ErrorMaps[fmt.Sprint(err)]; ok {
|
||||
exception(fmt.Sprint(err), context)
|
||||
return
|
||||
|
Reference in New Issue
Block a user