IContentService.GetById returning null while published content is available
I have a node in it's IPublishedContent variant. Now when I try to get it from the IContentService.GetById the content service returns null.
You can see that the publishedContent has a value, but why does the IContentService not return the published content as IContent? I need it to delete the content programatically.
I know IContentService is initialized properly because I can get other items with it.
Got a solution. Instead of parsing the publishedContent.Id I need to give it the Key. Which is weird because the method accepts both. But Id seems to be broken for whatever reason in our project.
IContentService.GetById returning null while published content is available
I have a node in it's
IPublishedContentvariant. Now when I try to get it from theIContentService.GetByIdthe content service returnsnull.You can see that the
publishedContenthas a value, but why does theIContentServicenot return the published content asIContent? I need it to delete the content programatically.I know
IContentServiceis initialized properly because I can get other items with it.Got a solution. Instead of parsing the
publishedContent.IdI need to give it theKey. Which is weird because the method accepts both. ButIdseems to be broken for whatever reason in our project.is working on a reply...
This forum is in read-only mode while we transition to the new forum.
You can continue this topic on the new forum by tapping the "Continue discussion" link below.