diff --git a/sao/CHANGELOG b/sao/CHANGELOG index 09abd951e7..c2b81bcb81 100644 --- a/sao/CHANGELOG +++ b/sao/CHANGELOG @@ -1,3 +1,4 @@ +* Escape completion content with custom format (issue14363) Version 7.0.39 - 2025-11-02 --------------------------- diff --git a/sao/src/common.js b/sao/src/common.js index ad66ccf082..5182bf2ecf 100644 --- a/sao/src/common.js +++ b/sao/src/common.js @@ -3840,9 +3840,13 @@ }, _format: function(content) { if (this.format) { - return this.format(content); + content = this.format(content); + } + if (content instanceof jQuery) { + return content; + } else { + return jQuery('').text(content); } - return jQuery('').text(content); }, _format_action: function(content) { if (this.format_action) {