mirror of
https://gitlab.com/comunic/comunicmobile
synced 2025-07-03 15:13:29 +00:00
Can change conversation image
This commit is contained in:
@ -100,6 +100,15 @@ class ConversationsHelper {
|
||||
.removeElement((t) => t.id == settings.convID);
|
||||
}
|
||||
|
||||
/// Set a new conversation logo
|
||||
///
|
||||
/// Throws in case of failure
|
||||
static Future<void> changeImage(int convID, BytesFile file) async =>
|
||||
await APIRequest.withLogin("conversations/change_image")
|
||||
.addInt("convID", convID)
|
||||
.addBytesFile("file", file)
|
||||
.execWithFilesAndThrow();
|
||||
|
||||
/// Delete a conversation specified by its [id]
|
||||
Future<void> deleteConversation(int id) async =>
|
||||
await APIRequest.withLogin("conversations/delete")
|
||||
|
Reference in New Issue
Block a user