From 06a3a71eb9cfc9991efbc47783efe7576f551291 Mon Sep 17 00:00:00 2001 From: ekzyis Date: Fri, 13 Dec 2024 16:27:46 +0100 Subject: [PATCH] Use new TimeoutError --- lib/time.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/time.js b/lib/time.js index 2f3c6c30..2ccd0390 100644 --- a/lib/time.js +++ b/lib/time.js @@ -140,7 +140,7 @@ function timeoutPromise (timeout) { // if no timeout is specified, never settle if (!timeout) return - setTimeout(() => reject(new Error(`timeout after ${timeout / 1000}s`)), timeout) + setTimeout(() => reject(new TimeoutError(timeout)), timeout) }) }