diff --git a/context.js b/context.js index 659f837..9c5761a 100644 --- a/context.js +++ b/context.js @@ -49,7 +49,7 @@ Namespace.prototype.run = function (fn) { return context; } catch (exception) { - exception[ERROR_SYMBOL] = context; + if(! exception[ERROR_SYMBOL]) exception[ERROR_SYMBOL] = context; throw exception; } finally { @@ -74,7 +74,7 @@ Namespace.prototype.bind = function (fn, context) { return fn.apply(this, arguments); } catch (exception) { - exception[ERROR_SYMBOL] = context; + if(! exception[ERROR_SYMBOL]) exception[ERROR_SYMBOL] = context; throw exception; } finally {