From b58aff8a54c9a934b12e19403821e7f7b28f40de Mon Sep 17 00:00:00 2001 From: Jon Atkins Date: Fri, 15 Aug 2014 00:48:58 +0100 Subject: [PATCH] remove references to niantic variables in their 'nemesis.' object - not available since they introduced minification --- code/data_cache.js | 1 - code/map_data_request.js | 10 +--------- main.js | 9 +-------- 3 files changed, 2 insertions(+), 18 deletions(-) diff --git a/code/data_cache.js b/code/data_cache.js index 4002a937..c9dda218 100644 --- a/code/data_cache.js +++ b/code/data_cache.js @@ -2,7 +2,6 @@ // cache for map data tiles. window.DataCache = function() { - // stock site nemesis.dashboard.DataManager.CACHE_EXPIRY_MS_ = 18E4 - 3 minutes this.REQUEST_CACHE_FRESH_AGE = 3*60; // if younger than this, use data in the cache rather than fetching from the server this.REQUEST_CACHE_MAX_AGE = 15*60; // maximum cache age. entries are deleted from the cache after this time diff --git a/code/map_data_request.js b/code/map_data_request.js index cb55de9f..4da06919 100644 --- a/code/map_data_request.js +++ b/code/map_data_request.js @@ -26,17 +26,9 @@ window.MapDataRequest = function() { // this many tiles in one request this.NUM_TILES_PER_REQUEST = 4; - try { - // try and use the value from the stock site, if available - this.NUM_TILES_PER_REQUEST = nemesis.dashboard.config.TILES_PER_REQUEST_CACHE_EXP || 4; - } catch(e) {} // number of times to retry a tile after an error (including "error: TIMEOUT" now - as stock intel does) - this.MAX_TILE_RETRIES = 4; - try { - // stock has a variable for this - try to use it - this.MAX_TILE_RETRIES = nemesis.dashboard.DataManager.MAX_QUADKEY_RETRY_ATTEMPTS_; - } catch(e) {} + this.MAX_TILE_RETRIES = 5; // refresh timers this.MOVE_REFRESH = 3; //time, after a map move (pan/zoom) before starting the refresh processing diff --git a/main.js b/main.js index d94819c9..06e73e4f 100644 --- a/main.js +++ b/main.js @@ -67,13 +67,6 @@ document.getElementsByTagName('head')[0].innerHTML = '' //note: smartphone.css injection moved into code/smartphone.js + ''; -var enableRedeem = true; -try { - enableRedeem = nemesis.dashboard.config.ENABLE_PASSCODE_REDEMPTION; -} catch(e) { - console.warn('failed to check for stock intel nemesis.dashboard.config.ENABLE_PASSCODE_REDEMPTION'); -} - document.getElementsByTagName('body')[0].innerHTML = '' + '
Loading, please wait
' @@ -103,7 +96,7 @@ document.getElementsByTagName('body')[0].innerHTML = '' + ' ' + ' ' + '
' - + (enableRedeem?' ':'') + + ' ' + '
' + ' Permalink' + ' About IITC'