Merge pull request #5109 from matrix-org/t3chguy/fix/14951

Fix /op slash command
pull/21833/head
Michael Telatynski 2020-08-13 17:16:47 +01:00 committed by GitHub
commit fbb058a8e3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -733,7 +733,7 @@ export const Commands = [
const cli = MatrixClientPeg.get();
const room = cli.getRoom(roomId);
if (!room) return reject(_t("Command failed"));
const member = room.getMember(args);
const member = room.getMember(userId);
if (!member || getEffectiveMembership(member.membership) === EffectiveMembership.Leave) {
return reject(_t("Could not find user in room"));
}