diff options
Diffstat (limited to 'lib/console.js')
-rw-r--r-- | lib/console.js | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/console.js b/lib/console.js index 2a09329595..ff7fd4dadb 100644 --- a/lib/console.js +++ b/lib/console.js @@ -19,6 +19,8 @@ // OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE // USE OR OTHER DEALINGS IN THE SOFTWARE. +'use strict'; + var util = require('util'); function Console(stdout, stderr) { @@ -89,13 +91,13 @@ Console.prototype.timeEnd = function(label) { }; -Console.prototype.trace = function() { +Console.prototype.trace = function trace() { // TODO probably can to do this better with V8's debug object once that is // exposed. var err = new Error; err.name = 'Trace'; err.message = util.format.apply(this, arguments); - Error.captureStackTrace(err, arguments.callee); + Error.captureStackTrace(err, trace); this.error(err.stack); }; |