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("hostname")
a.classList.add(d.flags.online ? "online" : "offline") a.classList.add(d.flags.online ? "online" : "offline")
a.textContent = d.nodeinfo.hostname a.textContent = d.nodeinfo.hostname
if (d.nodeinfo.node_id in markers) {
a.href = "#" a.href = "#"
a.onclick = markers[d.nodeinfo.node_id] a.onclick = markers[d.nodeinfo.node_id]
}
td1.appendChild(a) td1.appendChild(a)
if ("location" in d.nodeinfo) { if ("location" in d.nodeinfo) {