This is more of a self-to-note.
If you are using IContentLoader.GetChildren<T>(ContentReference)
, one important thing to remember is this uses the current preferred language. Normally when you get children of a catalog, or a node, that would not be a problem, because a catalog entity – node or entry, will be available in every language supported by the catalog. So if you just want to get the children references, the language is not important. (Note that, if you just need the children references, IRelationRepository
should be a faster, more lightweight way to go, but that’s another story). If you want to get children in a specific language – which is the most common case, you know that you can use the other overload of GetChildren<T>(ContentReference, ILanguageSelector)
, where you can specify the language you want to load.
Continue reading “Beware of IContentLoader.GetChildren() for CatalogContent” →