FIX: Use @username instead of user:username
This commit is contained in:
parent
70f46d81a9
commit
ca4130f30d
|
@ -99,9 +99,9 @@ export default Em.Component.extend({
|
|||
const userFilter = this.get('searchedTerms.username');
|
||||
if (userFilter && userFilter.length !== 0)
|
||||
if (match.length !== 0)
|
||||
searchTerm = searchTerm.replace(match, ` user:${userFilter}`);
|
||||
searchTerm = searchTerm.replace(match, ` @${userFilter}`);
|
||||
else
|
||||
searchTerm += ` user:${userFilter}`;
|
||||
searchTerm += ` @${userFilter}`;
|
||||
else if (match.length !== 0)
|
||||
searchTerm = searchTerm.replace(match, '');
|
||||
|
||||
|
|
|
@ -105,7 +105,7 @@ test("update username through advanced search ui", assert => {
|
|||
|
||||
andThen(() => {
|
||||
assert.ok(exists('.search-options span:contains("admin")'), 'has "admin" pre-populated');
|
||||
assert.equal(find('.search input.full-page-search').val(), "none user:admin", 'has updated search term to "none user:admin"');
|
||||
assert.equal(find('.search input.full-page-search').val(), "none @admin", 'has updated search term to "none user:admin"');
|
||||
});
|
||||
});
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue