Merge pull request #1762 from famedly/krille/pass-reason-when-invite-to-room

chore: Pass reason parameter when invite user to a room
This commit is contained in:
Krille-chan 2024-04-12 11:52:18 +02:00 committed by GitHub
commit b31a49613f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 9 additions and 1 deletions

View File

@ -1216,7 +1216,15 @@ class Room {
}
/// Call the Matrix API to invite a user to this room.
Future<void> invite(String userID) => client.inviteUser(id, userID);
Future<void> invite(
String userID, {
String? reason,
}) =>
client.inviteUser(
id,
userID,
reason: reason,
);
/// Request more previous events from the server. [historyCount] defines how much events should
/// be received maximum. When the request is answered, [onHistoryReceived] will be triggered **before**