},
hasTag: function (task: Element, tag: string): Element | null {
- for (const child of task.children) {
- if (child.classList.contains("tag") && child.textContent === tag) {
+ for (const child of task.getElementsByClassName("tag")) {
+ if (child.textContent === tag) {
return child;
}
}