history: link only to markers that exist

This commit is contained in:
Nils Schneider 2015-03-20 23:11:04 +01:00
parent 8ae4a23179
commit 4d5c367507

View File

@ -311,8 +311,10 @@ function addToList(el, showContact, tf, markers, list) {
a.classList.add("hostname")
a.classList.add(d.flags.online ? "online" : "offline")
a.textContent = d.nodeinfo.hostname
a.href = "#"
a.onclick = markers[d.nodeinfo.node_id]
if (d.nodeinfo.node_id in markers) {
a.href = "#"
a.onclick = markers[d.nodeinfo.node_id]
}
td1.appendChild(a)
if ("location" in d.nodeinfo) {