Skip to content

Commit 0aec4f9

Browse files
Avoid an error on the enemy page when switching pages.
1 parent 882067c commit 0aec4f9

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

extension/changelog.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,8 @@
1717
"contributor": "DeKleineKobini"
1818
},
1919
{ "message": "Improved performance while using FF Scouter in some cases.", "contributor": "DeKleineKobini" },
20-
{ "message": "Route tornpal requests through the background to bypass Torn's CSP policy on Firefox.", "contributor": "DeKleineKobini" }
20+
{ "message": "Route tornpal requests through the background to bypass Torn's CSP policy on Firefox.", "contributor": "DeKleineKobini" },
21+
{ "message": "Avoid an error on the enemy page when switching pages.", "contributor": "DeKleineKobini" }
2122
],
2223
"changes": [{ "message": "Better optimize calls to tornpal.", "contributor": "DeKleineKobini" }],
2324
"removed": []

extension/scripts/features/enemy-filter/ttEnemyFilter.js

+2
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,8 @@
2121
if (!feature.enabled()) return;
2222

2323
const content = findContainer("Enemy Filter", { selector: "main" });
24+
if (!content) return;
25+
2426
const statsEstimates = localFilters["Stats Estimate"]?.getSelections(content);
2527
if (!statsEstimates?.length) return;
2628

0 commit comments

Comments
 (0)