Closed ynshung closed 8 months ago
@adsuth I have a problem with the implementation: since I set the default extra option as true, the option does not work at all. Disabling it does not affect the local storage's yt-extraopts
at YouTube's website but the other options work as expected.
I've checked and see that up till pingChanges
the content is correct showing fullScreenDoubleClick: false
. Do you have an idea of what might causes this bug?
Hi @ynshung, I'm not 100% sure, but I think it might be this here (at src/lib/retrieveFromStorage.ts:30):
This is only checking if the option in storage is truthy, if it isnt, then it applies the default value.
So setting the new option to false will make it use the default value, true.
This issue doesnt exist for setting false values to false because it just uses the default which is false. (just to clarify because that confused to me when i was looking into this)
Solution is to make this check more explicit, not sure why I commented on it instead of just changing it, maybe there was an issue checking if it was null? Not sure.
Closes #207