From 7a268860407d723b36f75009a6dff50d3cd5adc9 Mon Sep 17 00:00:00 2001 From: TJ Holowaychuk Date: Fri, 13 Sep 2013 20:54:52 -0700 Subject: [PATCH] change app.onerror to ignore 404s so you can easily unwind the stack for 404s --- lib/application.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/application.js b/lib/application.js index 4b9b5c3..a232ec4 100644 --- a/lib/application.js +++ b/lib/application.js @@ -145,7 +145,9 @@ app.callback = function(){ */ app.onerror = function(err){ - if (this.outputErrors) console.error(err.stack); + if (!this.outputErrors) return; + if (404 == err.status) return; + console.error(err.stack); }; /**