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

Prevent an update/status call to a undefined url

This commit is contained in:
peteruithoven 2015-06-17 10:31:19 +02:00
parent 5e451d13c1
commit ef141ea859

View File

@ -53,14 +53,15 @@
//console.log(" _boxData: ",_boxData); //console.log(" _boxData: ",_boxData);
_title.text(_boxData.wifiboxid); _title.text(_boxData.wifiboxid);
setNetworkStatus(NetworkAPI.STATUS.CONNECTED);
var drawLink = (_boxData.link)? _boxData.link : boxURL; var drawLink = (_boxData.link)? _boxData.link : boxURL;
_page.find("#drawItem a").attr("href",drawLink); _page.find("#drawItem a").attr("href",drawLink);
_networkAPI.init(boxURL); _networkAPI.init(boxURL);
retrieveNetworkStatus();
_updateAPI.init(boxURL); _updateAPI.init(boxURL);
setNetworkStatus(NetworkAPI.STATUS.CONNECTED);
retrieveNetworkStatus();
}); });
$.mobile.document.on( "pagebeforehide", PAGE_ID, function( event, data ) { $.mobile.document.on( "pagebeforehide", PAGE_ID, function( event, data ) {
clearTimeout(_retryRetrieveStatusDelay); clearTimeout(_retryRetrieveStatusDelay);