report originating error for GetReference failure

This commit is contained in:
deads2k
2014-10-17 11:54:07 -04:00
parent b01126322b
commit 2c35c06727
2 changed files with 2 additions and 2 deletions

View File

@@ -34,7 +34,7 @@ func RecoverPanics(handler http.Handler) http.Handler {
if x := recover(); x != nil {
w.WriteHeader(http.StatusInternalServerError)
fmt.Fprint(w, "apis panic. Look in log for details.")
glog.Infof("APIServer panic'd on %v %v: %#v\n%s\n", req.Method, req.RequestURI, x, debug.Stack())
glog.Infof("APIServer panic'd on %v %v: %v\n%s\n", req.Method, req.RequestURI, x, debug.Stack())
}
}()
defer httplog.NewLogged(req, &w).StacktraceWhen(