We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 78f8915 + a5b8524 commit c025ee6Copy full SHA for c025ee6
panic.go
@@ -19,7 +19,8 @@ func PanicFilter(c *Controller, fc []Filter) {
19
// It cleans up the stack trace, logs it, and displays an error page.
20
func handleInvocationPanic(c *Controller, err interface{}) {
21
error := NewErrorFromPanic(err)
22
- if error == nil {
+ if error == nil && DevMode {
23
+ // Only show the sensitive information in the debug stack trace in development mode, not production
24
ERROR.Print(err, "\n", string(debug.Stack()))
25
c.Response.Out.WriteHeader(500)
26
c.Response.Out.Write(debug.Stack())
0 commit comments