Fix building tracker on initial setup

This commit is contained in:
relikd
2020-09-23 21:23:28 +02:00
parent c28ed301ec
commit 087bd5384b
2 changed files with 3 additions and 1 deletions

View File

@@ -1,5 +1,5 @@
function lookup_rank_js(bundle_id) {
loadJSON('/stats/rank.json', function(response) {
loadJSON('/results/rank.json', function(response) {
let json = JSON.parse(response);
if (!json) { return; }
let rank = json[bundle_id];

View File

@@ -22,6 +22,8 @@ def enum_local(list_name):
def is_tracker(domain):
global known_trackers
if known_trackers is None:
if not mylib.file_exists(fname_tracker('all.txt')):
process()
known_trackers = list(enum_local('all.txt'))
return mylib.bintree_lookup(known_trackers, domain[::-1])