1
0
Fork 0

catch if given atree does not exist

This commit is contained in:
reschan 2022-06-24 09:50:18 +07:00
parent 32ee15dc2b
commit cba1bb5eb0

View file

@ -4,6 +4,8 @@ function construct_AT(elem, tree) {
console.log("constructing ability tree UI");
document.getElementById("atree-active").innerHTML = ""; //reset all atree actives - should be done in a more general way later
elem.innerHTML = ""; //reset the atree in the DOM
if (tree === undefined) {return false;}
// add in the "Active" title to atree
let active_row = document.createElement("div");