Merge pull request #23264 from nextcloud/bug/23177/escape-html
Add local version of escapeHTML
This commit is contained in:
commit
2ec160aec8
|
@ -57,6 +57,14 @@ function highlightInput($input) {
|
|||
* @param {int} userListLimit page size for result list
|
||||
*/
|
||||
function addSelect2 ($elements, userListLimit) {
|
||||
var escapeHTML = function (text) {
|
||||
return text.toString()
|
||||
.split('&').join('&')
|
||||
.split('<').join('<')
|
||||
.split('>').join('>')
|
||||
.split('"').join('"')
|
||||
.split('\'').join(''');
|
||||
};
|
||||
if (!$elements.length) {
|
||||
return;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue