mirror of
https://github.com/SukkaW/Surge.git
synced 2026-01-29 01:51:52 +08:00
Chore: make ESLint and TypeScript happy
This commit is contained in:
@@ -139,10 +139,6 @@ export class ResponseError<T extends UndiciResponseData | Response> extends Erro
|
||||
const statusCode = 'statusCode' in res ? res.statusCode : res.status;
|
||||
super('HTTP ' + statusCode + ' ' + args.map(_ => inspect(_)).join(' '));
|
||||
|
||||
if ('captureStackTrace' in Error) {
|
||||
Error.captureStackTrace(this, ResponseError);
|
||||
}
|
||||
|
||||
// eslint-disable-next-line sukka/unicorn/custom-error-definition -- deliberatly use previous name
|
||||
this.name = this.constructor.name;
|
||||
this.res = res;
|
||||
|
||||
Reference in New Issue
Block a user