From c70abac4f47528dc3152c59cd7953e5679576255 Mon Sep 17 00:00:00 2001 From: Peter Dolkens Date: Tue, 17 Jan 2023 03:48:40 +0100 Subject: [PATCH] Fix double loading on Chrome --- src/manifest.firefox.json | 3 ++- src/manifest.json | 8 +------- src/web_resources/HangarXPLOR.js | 5 +++-- 3 files changed, 6 insertions(+), 10 deletions(-) diff --git a/src/manifest.firefox.json b/src/manifest.firefox.json index 4a294d5..3c87e5f 100644 --- a/src/manifest.firefox.json +++ b/src/manifest.firefox.json @@ -1,7 +1,8 @@ { "browser_specific_settings": { "gecko": { - "id": "HangarXPLOR@ddrit.com" + "id": "HangarXPLOR@ddrit.com", + "strict_min_version": "109.0" } } } \ No newline at end of file diff --git a/src/manifest.json b/src/manifest.json index a137564..e2d26a7 100644 --- a/src/manifest.json +++ b/src/manifest.json @@ -84,11 +84,5 @@ "debug/*.html" ] } - ], - - "browser_specific_settings": { - "gecko": { - "id": "HangarXPLOR@ddrit.com" - } - } + ] } \ No newline at end of file diff --git a/src/web_resources/HangarXPLOR.js b/src/web_resources/HangarXPLOR.js index 12e3b83..91e3e3c 100644 --- a/src/web_resources/HangarXPLOR.js +++ b/src/web_resources/HangarXPLOR.js @@ -10,11 +10,12 @@ HangarXPLOR._giftableCount = HangarXPLOR._giftableCount || 0; HangarXPLOR._packageCount = HangarXPLOR._packageCount || 0; HangarXPLOR._ltiCount = HangarXPLOR._ltiCount || 0; HangarXPLOR._cacheSalt = HangarXPLOR._cacheSalt || btoa(Math.random()); +HangarXPLOR._initCount = HangarXPLOR._initCount || 0; var RSI = RSI || {}; HangarXPLOR.Initialize = function() -{ +{ $.ajax({ url: '/ship-matrix/index', method: 'GET', @@ -110,4 +111,4 @@ HangarXPLOR.Initialize = function() }); } -HangarXPLOR.Initialize(); +if (HangarXPLOR._initCount++ == 0) HangarXPLOR.Initialize();