10 lines
255 B
TypeScript
10 lines
255 B
TypeScript
export default class PlayerError extends Error {
|
|
constructor(msg: string, name?: string) {
|
|
super();
|
|
this.name = name ?? 'PlayerError';
|
|
this.message = msg;
|
|
Error.captureStackTrace(this);
|
|
}
|
|
}
|
|
|
|
export { PlayerError };
|