heywesty 0 Posted March 21, 2021 Posted March 21, 2021 I’ve been attempting to setup the Trakt plugin on my server but have run into an issue where the select form field never populates with users. There are no errors in chrome dev tools. I found other similar posts on this forum and I wanted to debug and fix the issue but I’m unsure where the source code lives. Is it this github repo?
heywesty 0 Posted March 21, 2021 Author Posted March 21, 2021 I've debugged this as best I can. It appears the Trakt plugin javascript never fires for the versions I'm running (Emby Server `4.5.4.0` in a `linuxserver` docker container and Trakt `3.4.6.0`). I cloned the Trakt plugin Github repo I linked to above and made the following changes: move the JS to its own file wrap it in a `define` statement use the `'viewshow'` event to kick things off add a `data-controller="__plugin/traktjs"` attribute to the `div.pluginConfigurationPage` embed the JS in `GetPages` Plugin.cs and it appears to be working again for my server install. @Lukedo any of the steps I've taken above make sense regarding potential API changes in Emby? The Trakt JS doesn't appear to have been touched in years. I'm happy to PR them if I'm not making a mess here.
Luke 42077 Posted March 22, 2021 Posted March 22, 2021 Hi, if you're running a reverse proxy, this is probably caused by your content security policy that is rejecting the inline javascript. So yes, you're exactly right about the changes that are required, and feel free to submit that pull request to the trakt plugin.
heywesty 0 Posted March 22, 2021 Author Posted March 22, 2021 Thanks for getting back to me on this, really appreciate the input. 5 hours ago, Luke said: if you're running a reverse proxy, this is probably caused by your content security policy that is rejecting the inline javascript That's odd cos I am running a reverse proxy but of the 15+ services I have sat behind it Emby is the only one that has a content security policy. I see nothing in the NGINX configs suggesting it's enabled. 8 hours ago, Luke said: feel free to submit that pull request to the trakt plugin Will put it together ASAP.
heywesty 0 Posted May 30, 2021 Author Posted May 30, 2021 Opened a PR here to keep track of this: https://github.com/MediaBrowser/trakt/pull/19
Luke 42077 Posted May 30, 2021 Posted May 30, 2021 4 hours ago, heywesty said: Opened a PR here to keep track of this: https://github.com/MediaBrowser/trakt/pull/19 Hi, that's great, thanks for doing that! I'll go over it shortly.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now