SEO assistance for MODX — Optimize your MODX Revolution pages for the best Search Engine performance. Follow https://twitter.com/sterc for tips and updates.
function getAlternateLinks has unnecessary conext switch ($this->modx->switchContext($contextKey);), that could be the reason for inappropriate behavior.
In some cases (when some resources has no translation in some contexts), the context is fixed in the wrong state, as a result of which in the following cycles within sitemap() functionn we get the wrong (empty) result of the function makeUrl.
function getAlternateLinks has unnecessary conext switch ($this->modx->switchContext($contextKey);), that could be the reason for inappropriate behavior.
In some cases (when some resources has no translation in some contexts), the context is fixed in the wrong state, as a result of which in the following cycles within sitemap() functionn we get the wrong (empty) result of the function makeUrl.
Solution (tested) is: