Jump to content

LibraryManager.GetItemsResult() no providerId info


chef

Recommended Posts

Using this:

                var result = LibraryManager.GetItemsResult(new InternalItemsQuery()
                {
                    User = users[i],
                    Recursive = true,
                    IncludeItemTypes = new[] {nameof(Movie)}
                });

 

Then:

                foreach (var item in result.Items)
                {       
					//streamWriter is upthere^^^ doesn't matter
                    sw.WriteLine($"{user.Id},{ item.ProviderIds.FirstOrDefault(p => p.Key == ("Tmdb")).Value},{ (item.IsFavorite ? 1 : 0) }");
                }

 

Causes this:

providerErrors.thumb.png.07c8a05977c1824e720949b35aa5171f.png

 

But, the provider data is there as shown in the swagger:

providerErrors_2.png.c07229d7757348dcbd33e1c8545cba2d.png

 

 

Link to comment
Share on other sites

HI, it's just a type change. You'll need to recompile the plugin against a newer nuget package. This change might have been in 4.6 if i recall correctly, so if that's the case you can use a 4.6 nuget package and still target the stable server. if not then you'll have to target a 4.7 beta package.

Link to comment
Share on other sites

4 minutes ago, Luke said:

HI, it's just a type change. You'll need to recompile the plugin against a newer nuget package. This change might have been in 4.6 if i recall correctly, so if that's the case you can use a 4.6 nuget package and still target the stable server. if not then you'll have to target a 4.7 beta package.

Perfect! Many thanks!

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...