Small fix to compile ts again

Old code was okay according to mdn: https://developer.mozilla.org/de/docs/Web/API/Document/createTreeWalker
Typescript not liking it: https://github.com/microsoft/TypeScript/issues/33462#issuecomment-912517410

We fine with removing the params as it was optional at all and we set to false
This commit is contained in:
Serraniel 2021-11-05 22:40:51 +01:00
parent 03f9f9c34a
commit 14bc1051a3
Signed by: Serraniel
GPG key ID: 3690B4E7364525D3

View file

@ -43,7 +43,7 @@ export function findTextNodes(baseNode: Node): Array<Node> {
baseNode = document.documentElement;
}
let walker = document.createTreeWalker(baseNode, NodeFilter.SHOW_TEXT, null, false);
let walker = document.createTreeWalker(baseNode, NodeFilter.SHOW_TEXT, null);
let node;
let results = [];
while (node = walker.nextNode()) {