-
-
Notifications
You must be signed in to change notification settings - Fork 2
Description
Checklist
- This is an issue for YtcFilter, not LiveTL or HyperChat. I will go to the LiveTL repo to report an issue with LiveTL, or the HyperChat repo to report an issue with HyperChat.
- This issue is not a matter of opinion. If it is, I will use the feature suggestion issue template.
- I have checked for a duplicate or similar issue. I made sure to check closed issues as well.
- I am still able to reproduce the issue after I reinstall the extension.
- I have clear instructions to reproduce the bug, even on another machine.
- I am not suggesting a feature. If I am, I will use the feature suggestion issue template.
- By submitting this issue, you agree to follow our Code of Conduct
Describe the bug
When the live stream page is refreshed, messages already filtered before the refresh are no longer visible when ytcfilter reopen.
Steps To Reproduce
- Open a live stream and wait for some messages to be filtered and displayed in ytcfilter.
- Refresh the page.
Expected behavior
Previously filtered messages should still be visible after a refresh.
What browsers are you seeing the problem on?
Chrome
Anything else?
If I look in archives in ytcfilter settings I can see the messages previously filtered, but there is no video id or title (which I think is the cause of the refresh issue).
Looking a bit at the code, I see the chat-interceptor.ts
is supposed to get video/channel info, but fail with "Cannot read properties of undefined (reading '__dataHost')". It looks like the following property is no longer available (window as any).parent.yt.config_.SBOX_SETTINGS.SEARCHBOX_COMPONENT
, not sure why but maybe a change on youtube side.
I checked if this was available elsewhere and found another property in the window ytInitialData
that looks promising. I think that changing the code that get video/channel info to use (window as any).parent.ytInitialData.contents.twoColumnWatchNextResults...
instead may work.