summaryrefslogtreecommitdiff
path: root/includes/components/planner.inc
diff options
context:
space:
mode:
Diffstat (limited to 'includes/components/planner.inc')
-rw-r--r--includes/components/planner.inc6
1 files changed, 4 insertions, 2 deletions
diff --git a/includes/components/planner.inc b/includes/components/planner.inc
index 9be9cb7..aed4e56 100644
--- a/includes/components/planner.inc
+++ b/includes/components/planner.inc
@@ -520,7 +520,9 @@ function day($display, $diff): void { if ($diff < 0) $disabled = true; else $dis
document.getElementById("associated-results").innerHTML = "";
for (let pony of availablePonies) {
- document.getElementById("associated-results").innerHTML += document.getElementById("list-pony-" + pony).outerHTML;
+ if (document.getElementById("list-pony-" + pony)) {
+ document.getElementById("associated-results").innerHTML += document.getElementById("list-pony-" + pony).outerHTML;
+ }
}
document.getElementById("list").style.display = "none";
@@ -970,7 +972,7 @@ function day($display, $diff): void { if ($diff < 0) $disabled = true; else $dis
document.getElementById("search-results").innerHTML = "";
for (let result of results) {
- document.getElementById("search-results").innerHTML += document.getElementById("list-pony-" + result.id).outerHTML;
+ if (document.getElementById("list-pony-" + result.id)) document.getElementById("search-results").innerHTML += document.getElementById("list-pony-" + result.id).outerHTML;
}
console.log(results);