Comparing version 1.5.10 to 1.5.11
@@ -315,2 +315,3 @@ var domain = require('domain') | ||
var stack = FormatStackTrace.call(this, err, frames) | ||
, currentStack | ||
, i, l | ||
@@ -325,3 +326,5 @@ | ||
if ('_trycatchNewCallback' === frames[i].getFunctionName()) { | ||
stack += delimitter + frames[i].getFunction()._trycatchCurrentStack | ||
// In case long-stack-traces were toggled | ||
currentStack = frames[i].getFunction()._trycatchCurrentStack | ||
stack += currentStack ? delimitter + frames[i].getFunction()._trycatchCurrentStack : '' | ||
break | ||
@@ -328,0 +331,0 @@ } |
{ | ||
"name": "trycatch", | ||
"version": "1.5.10", | ||
"version": "1.5.11", | ||
"description": "An asynchronous domain-based exception handler with long stack traces for node.js", | ||
@@ -5,0 +5,0 @@ "homepage": "http://github.com/CrabDude/trycatch", |
@@ -81,3 +81,3 @@ var trycatch = require('../lib/trycatch') | ||
process.nextTick(function() { | ||
assert(err.stack.split('\n')[2].indexOf('timeout') !== -1) | ||
assert(err.stack.split('\n')[2].indexOf('timers.js') !== -1) | ||
assert.equal(err.stack.split(delimitter).length, longStackTraces ? 2 : 1) | ||
@@ -84,0 +84,0 @@ done() |
58158
1038