Fix ability to invite existing mx users
Bug introduced by https://github.com/matrix-org/matrix-react-sdk/pull/1432 We should really not be using string constant literals all over the place. We'd be less likely to run into this sort of bug these address types weren't copied literals.
This commit is contained in:
parent
1699c37fcf
commit
3c99b2af3d
1 changed files with 1 additions and 1 deletions
|
@ -28,7 +28,7 @@ export function inviteToRoom(roomId, addr) {
|
||||||
|
|
||||||
if (addrType == 'email') {
|
if (addrType == 'email') {
|
||||||
return MatrixClientPeg.get().inviteByEmail(roomId, addr);
|
return MatrixClientPeg.get().inviteByEmail(roomId, addr);
|
||||||
} else if (addrType == 'mx') {
|
} else if (addrType == 'mx-user-id') {
|
||||||
return MatrixClientPeg.get().invite(roomId, addr);
|
return MatrixClientPeg.get().invite(roomId, addr);
|
||||||
} else {
|
} else {
|
||||||
throw new Error('Unsupported address');
|
throw new Error('Unsupported address');
|
||||||
|
|
Loading…
Reference in a new issue