Skip to content

Commit

Permalink
fix(ckeditor): early abort object mentions on closing bracket
Browse files Browse the repository at this point in the history
  • Loading branch information
jeabakker committed Aug 25, 2023
1 parent 68a5eb2 commit b397601
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions mod/ckeditor/views/default/ckeditor/config/mentions.js
Expand Up @@ -61,6 +61,12 @@ define(['elgg/Ajax'], function(Ajax) {
}

function findObjects(queryText) {
if (queryText.includes(']')) {
// to allow the use of 'some [text] more text'
// without triggering the mentions functionality
return [];
}

return getLivesearch(queryText, 'objects');
}

Expand Down

0 comments on commit b397601

Please sign in to comment.