This commit is contained in:
Cat /dev/Nulo 2022-11-25 22:11:35 -03:00
parent 70a8125fa8
commit 0c3fca6a21

View file

@ -48,7 +48,7 @@ function recurseElement(page: Page, el: Element) {
}
if (["audio", "video", "img", "source"].includes(el.name)) {
if (el.attribs.src) {
checkUrl(report, rawHtml, el, el.attribs.src);
checkUrl(page, el, el.attribs.src);
} else {
report.things.push({
type: "media-no-src",
@ -64,7 +64,7 @@ function recurseElement(page: Page, el: Element) {
}
}
function checkUrl(report: Report, rawHtml: string, el: Element, url: string) {
function checkUrl({ report, rawHtml }: Page, el: Element, url: string) {
if (isHttp(url)) {
report.things.push({
type: "media-http",