mirror of
https://github.com/mattermost/mattermost.git
synced 2025-02-25 18:55:24 -06:00
PLT-4821 Fix highlighting of wildcard search terms. (#4976)
This commit is contained in:
committed by
Joram Wilander
parent
c3f60d7ced
commit
96697c8cf7
@@ -395,7 +395,13 @@ function parseSearchTerms(searchTerm) {
|
||||
}
|
||||
|
||||
// remove punctuation from each term
|
||||
terms = terms.map((term) => term.replace(puncStart, '').replace(puncEnd, ''));
|
||||
terms = terms.map((term) => {
|
||||
term.replace(puncStart, '');
|
||||
if (term.charAt(term.length - 1) !== '*') {
|
||||
term.replace(puncEnd, '');
|
||||
}
|
||||
return term;
|
||||
});
|
||||
|
||||
return terms;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user