discord-player-play-dl/src/utils/PlayerError.ts

8 lines
229 B
TypeScript
Raw Normal View History

2021-04-06 19:06:18 +05:00
export default class PlayerError extends Error {
constructor(msg: string, name?: string) {
super();
this.name = name ?? "PlayerError";
this.message = msg;
Error.captureStackTrace(this);
}
}