Jump to content
LaunchBox Community Forums

PluginHelper.DataManager.GetAllParents()


Recommended Posts

Hi @Jason Carr. I get the following error when trying to use the new API call to GetAllParents(). Would you please check it out when you have time?

Unable to cast object of type 'System.Collections.Generic.KeyValuePair`2[System.String,Unbroken.LaunchBox.Data.Parent]' to type 'Unbroken.LaunchBox.Plugins.Data.IParent'.

I'm trying to adapt my plugins to the new nesting scheme.

Link to comment
Share on other sites

7 hours ago, Jason Carr said:

I have this fixed for the next beta @eatkinola.

Thanks, Jason -- no more error! I have a follow up question ... do all platforms (and potentially playlists if treated like platforms) still have a platform category? I know platform.Category will now just return an empty string, but would navigating up the nested structure always lead to a category?

  • Like 1
Link to comment
Share on other sites

14 hours ago, eatkinola said:

Thanks, Jason -- no more error! I have a follow up question ... do all platforms (and potentially playlists if treated like platforms) still have a platform category? I know platform.Category will now just return an empty string, but would navigating up the nested structure always lead to a category?

No, not necessarily. Platforms are not guaranteed to have a parent if the user chooses to place them in the root. It's also important to note that categories, platforms, and playlists can all also be placed in multiple locations (multiple parents).

Link to comment
Share on other sites

2 hours ago, Jason Carr said:

No, not necessarily. Platforms are not guaranteed to have a parent if the user chooses to place them in the root. It's also important to note that categories, platforms, and playlists can all also be placed in multiple locations (multiple parents).

Thanks -- I really appreciate you steering me in the right direction.

  • Like 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...