From 1547fe2c7f10745a30fd032562aaa12e671c4fee Mon Sep 17 00:00:00 2001 From: Sindre Sorhus Date: Sun, 14 May 2017 21:59:23 +0700 Subject: [PATCH] Define error name manually so it will work when minified --- index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/index.js b/index.js index 385f04e..af0620d 100644 --- a/index.js +++ b/index.js @@ -3,7 +3,7 @@ class TimeoutError extends Error { constructor(message) { super(message); - this.name = this.constructor.name; + this.name = 'TimeoutError'; } }