Details
-
Improvement
-
Resolution: Fixed
-
Major
-
7.1
-
Unknown
-
N/A
-
N/A
-
Description
Currently, to determine if a custom displayer exists for a property, various places are checked (XWiki document in the current wiki, XWiki document in the main wiki and template file).
However, when determining if a template file exists to be used as a custom displayer, XWiki.evaluateTemplate(...) is used and the result is verified if it is empty.
With the addition of the TemplateManager (XWIKI-11252), we can now check if a template exists (TemplateManager#getTemplate(...)) without having to render it, so we can avoid a costly and possibly dangerous operation.