0
0
mirror of https://github.com/Doodle3D/doodle3d-connect.git synced 2024-12-25 01:53:48 +01:00

Fix: boxes are actually removed when they don't respond

This commit is contained in:
peteruithoven 2013-10-10 00:15:50 +02:00
parent 8465d61845
commit 81a80da7c5

View File

@ -99,6 +99,7 @@ function checkBox(box) {
updateIntro(); updateIntro();
} }
}).fail(function() { }).fail(function() {
//console.log("box not alive: "+box.wifiboxid);
numBoxesChecking--; numBoxesChecking--;
removeBox(box); removeBox(box);
updateIntro(); updateIntro();
@ -115,7 +116,8 @@ function boxExists(localip){
return $list.find("a[id|='"+localip+"']").length > 0; return $list.find("a[id|='"+localip+"']").length > 0;
} }
function removeBox(box) { function removeBox(box) {
$list.remove("a[id|='"+box.localip+"']"); var $element = $list.find("a[id|='"+box.localip+"']");
$element.remove();
} }
function updateIntro() { function updateIntro() {