File tree Expand file tree Collapse file tree 1 file changed +4
-6
lines changed
modules/ROOT/partials/configuration Expand file tree Collapse file tree 1 file changed +4
-6
lines changed Original file line number Diff line number Diff line change @@ -26,15 +26,13 @@ tinymce.init({
2626 usersRequest = fetch('/users');
2727 }
2828 usersRequest.then((users) => {
29- // query.term is the text the user typed after the '@'
30- users = users.filter((user) => {
31- return user.name.indexOf(query.term.toLowerCase()) !== -1;
32- });
29+ /* `query.term` is the text the user typed after the '@' */
30+ users = users.filter((user) => user.name.toLowerCase().includes(query.term.toLowerCase()))
3331
3432 users = users.slice(0, 10);
3533
36- // Where the user object must contain the properties `id` and `name`
37- // but you could additionally include anything else you deem useful.
34+ /* Where the user object must contain the properties `id` and `name`
35+ but you could additionally include anything else you deem useful. */
3836 success(users);
3937 });
4038 }
You can’t perform that action at this time.
0 commit comments