Add slash command for changing room name
Signed-off-by: Christopher Medlin <christopherjmedlin@protonmail.com>
This commit is contained in:
parent
c11d0bdf0c
commit
c89b6e1e27
3 changed files with 14 additions and 0 deletions
|
@ -135,6 +135,18 @@ export const CommandMap = {
|
|||
},
|
||||
}),
|
||||
|
||||
name: new Command({
|
||||
name: 'name',
|
||||
args: '<name>',
|
||||
description: _td('Sets the room name'),
|
||||
runFn: function(roomId, args) {
|
||||
if (args) {
|
||||
return success(MatrixClientPeg.get().setRoomName(roomId, args));
|
||||
}
|
||||
return reject(this.getUsage());
|
||||
},
|
||||
}),
|
||||
|
||||
invite: new Command({
|
||||
name: 'invite',
|
||||
args: '<user-id>',
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue