Merge pull request #1128 from matrix-org/luke/fix-invite-user-id-case
Fix ability to invite users with caps in their user IDs
This commit is contained in:
commit
f7a22cccb6
1 changed files with 4 additions and 3 deletions
|
@ -178,7 +178,7 @@ module.exports = React.createClass({
|
||||||
},
|
},
|
||||||
|
|
||||||
onQueryChanged: function(ev) {
|
onQueryChanged: function(ev) {
|
||||||
const query = ev.target.value.toLowerCase();
|
const query = ev.target.value;
|
||||||
if (this.queryChangedDebouncer) {
|
if (this.queryChangedDebouncer) {
|
||||||
clearTimeout(this.queryChangedDebouncer);
|
clearTimeout(this.queryChangedDebouncer);
|
||||||
}
|
}
|
||||||
|
@ -271,10 +271,11 @@ module.exports = React.createClass({
|
||||||
query,
|
query,
|
||||||
searchError: null,
|
searchError: null,
|
||||||
});
|
});
|
||||||
|
const queryLowercase = query.toLowerCase();
|
||||||
const results = [];
|
const results = [];
|
||||||
MatrixClientPeg.get().getUsers().forEach((user) => {
|
MatrixClientPeg.get().getUsers().forEach((user) => {
|
||||||
if (user.userId.toLowerCase().indexOf(query) === -1 &&
|
if (user.userId.toLowerCase().indexOf(queryLowercase) === -1 &&
|
||||||
user.displayName.toLowerCase().indexOf(query) === -1
|
user.displayName.toLowerCase().indexOf(queryLowercase) === -1
|
||||||
) {
|
) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue