Skip to content

Commit

Permalink
Simplify error
Browse files Browse the repository at this point in the history
  • Loading branch information
sindresorhus committed Nov 23, 2016
1 parent 3555910 commit e6bed58
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions index.js
Expand Up @@ -3,8 +3,7 @@
class TimeoutError extends Error {
constructor(message) {
super(message);
this.name = 'TimeoutError';
this.message = message;
this.name = this.constructor.name;
}
}

Expand Down

0 comments on commit e6bed58

Please sign in to comment.