Details
-
Bug
-
Status: Closed
-
Blocker
-
Resolution: Fixed
-
2.21.02
-
None
-
None
Description
When the broken links checker finds a broken link in a document, it creates a 'brokenlinks:link' node under the handle of the document. When such a node is present, a facetselect on the document will return the brokenlinks:link node under the handle instead of the document node if the 'brokenlinks:link' node is an earlier child node than the document node itself.
The net effect is that once the broken links checker reported a broken link in a document, that document is immediately removed from a site after it has been edited and published again. Reason: the edit action+publish action moves the document node below the brokenlinks:link node, and the 'single' mode of the HST facetselect for the live and preview content tree will select the first child node, which will be the brokenlinks:link node instead of the document node.
Steps to reproduce:
1. in the console, go to the handle of a document
2. add the mixin 'brokenlinks:brokenlinks' to the handle
3. under the handle, add a node named 'brokenlinks:link' of type 'brokenlinks:link'
4. save changes
5. in the CMS, open the same document
6. edit the opened document
7. save & close the document
8. publish the document
Expected behavior: the document can be seen on the live site
Actual behavior: the document is not shown anymore on the live site (because the virtual tree under the hst:content node of the site contains the 'brokenlinks:link' node under the handle instead of the document node).