Closed WofWca closed 1 month ago
Thanks a lot!
lastTryDate do not hold valid date format so the code wouldn't work without my commit.
Will do some updates on this but very good thanks.
Also lastTryDate always gets updated, I've pushed a commit with slight adjustment to the logic which should fix the mentioned issue
Since the background scripts in MV3 are non-persistent, they might shut down often, losing all
setInterval
timers.If the background script doesn't live longer that refresh period, then it will never refresh.
This commit checks
lastTryDate
and doessetTimeout
based on that. If the list has not been refreshed for longer thanrefreshRate
, we'll refresh it immediately.FYI however there is another bug: if a fetch fails,
lastTryDate
does not get stored in local storage, so a refresh attempt will happen immediately as the background script starts. This is not a big problem.