Bugfix: parseDom return statement

This commit is contained in:
DarkCat09 2023-09-11 13:01:27 +04:00
parent 3a7abd93d9
commit 456a472031
No known key found for this signature in database
GPG Key ID: 0A26CD5B3345D6E3

View File

@ -22,7 +22,7 @@ export class HandlerInput {
this.redirectPath = redirectPath;
}
parseDom() {
parseDom(): JSDOM {
const dom = new JSDOM(this.data, { url: this.url });
const links = dom.window.document.getElementsByTagName("a");
@ -38,9 +38,11 @@ export class HandlerInput {
// ignore TypeError: Invalid URL
}
}
return dom;
}
getUrl() {
getUrl(): string {
return this.url;
}
}