From 4fe02e23af1e0c746b30132205fbd1fbddb2a079 Mon Sep 17 00:00:00 2001 From: Jeremiah Senkpiel Date: Fri, 18 Mar 2016 17:08:44 -0400 Subject: [PATCH] timers: give Timeouts a constructor name MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Refs: https://github.com/nodejs/node/pull/5792 PR-URL: https://github.com/nodejs/node/pull/5793 Reviewed-By: Colin Ihrig Reviewed-By: Rich Trott Reviewed-By: James M Snell Reviewed-By: Сковорода Никита Андреевич --- lib/timers.js | 2 +- test/message/timeout_throw.out | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/timers.js b/lib/timers.js index 99010d424a984e..bec1d2e2180901 100644 --- a/lib/timers.js +++ b/lib/timers.js @@ -439,7 +439,7 @@ exports.clearInterval = function(timer) { }; -const Timeout = function(after) { +function Timeout(after) { this._called = false; this._idleTimeout = after; this._idlePrev = this; diff --git a/test/message/timeout_throw.out b/test/message/timeout_throw.out index 1e545a1db15dfc..2a049a157acab4 100644 --- a/test/message/timeout_throw.out +++ b/test/message/timeout_throw.out @@ -2,6 +2,6 @@ undefined_reference_error_maker; ^ ReferenceError: undefined_reference_error_maker is not defined - at ._onTimeout (*test*message*timeout_throw.js:*:*) + at Timeout._onTimeout (*test*message*timeout_throw.js:*:*) at tryOnTimeout (timers.js:*:*) at Timer.listOnTimeout (timers.js:*:*)