-
-
Notifications
You must be signed in to change notification settings - Fork 5
Closed
Description
What
The power user script fails with the error "history is null". On line 804 the variable history should be assigned with the #history element, but the is none such in the DOM of e.g. https://world.openfoodfacts.org/product/6111099000247
power-user-script/OpenFoodFactsPower.user.js
Line 829 in 41c39a5
| var history = document.getElementById("history"); |
Uncaught (in promise) TypeError: history is null
window["__f__lsl0fzv4.kt9"]/</< moz-extension://b44e721e-003d-49fa-8d38-f046ab61ffb4/userscripts/Open-Food-Facts-power-user-script.user.js?id=fa8fc560-58ad-4b78-9bf9-c5916ff18b57:852
window["__f__lsl0fzv4.kt9"]/< moz-extension://b44e721e-003d-49fa-8d38-f046ab61ffb4/userscripts/Open-Food-Facts-power-user-script.user.js?id=fa8fc560-58ad-4b78-9bf9-c5916ff18b57:2837
Rt https://world.openfoodfacts.org/product/6111099000247:9
window["__f__lsl0fzv4.kt9"]/< moz-extension://b44e721e-003d-49fa-8d38-f046ab61ffb4/userscripts/Open-Food-Facts-power-user-script.user.js?id=fa8fc560-58ad-4b78-9bf9-c5916ff18b57:1
"__f__lsl0fzv4.kt9" moz-extension://b44e721e-003d-49fa-8d38-f046ab61ffb4/userscripts/Open-Food-Facts-power-user-script.user.js?id=fa8fc560-58ad-4b78-9bf9-c5916ff18b57:1
Rt https://world.openfoodfacts.org/product/6111099000247:9
o https://world.openfoodfacts.org/product/6111099000247:81
<anonymous> https://world.openfoodfacts.org/product/6111099000247:84
m https://world.openfoodfacts.org/product/6111099000247:78
6111099000247 line 9 > injectedScript:852:13
Steps to reproduce the behavior:
- Go to https://world.openfoodfacts.org/product/6111099000247
- Open Web Developer Tools and inspect the error
- Try to get DOM by manually executing
document.getElementById("history")in the web console.nullis returned.
Expected behavior
Power User Script should work in all cases
Platform (Desktop, Mobile, Hunger Games)
- OS: macOS Ventura 13.2.1
- Platform: Desktop
- Browser: Firefox 115.7.0esr
- Tampermonkey: v5.0.1
- OpenFoodFacts Version: 2024-02-02T20:39
Metadata
Metadata
Assignees
Labels
No labels
Type
Projects
Status
✅ Done