1
0
mirror of https://github.com/matrix-org/matrix-react-sdk.git synced 2025-11-07 10:46:24 +03:00

Inject stickers

This commit is contained in:
Richard Lewis
2018-01-04 09:53:26 +00:00
parent 7660176079
commit e96d199b28
3 changed files with 37 additions and 8 deletions

View File

@@ -275,6 +275,12 @@ class ContentMessages {
this.nextId = 0;
}
sendURLContentToRoom(url, roomId, info, text, matrixClient) {
return MatrixClientPeg.get().sendImageMessage(roomId, url, info, text).catch((e) => {
console.warn(`Failed to send content with URL ${url} to room ${roomId}`, e);
});
}
sendContentToRoom(file, roomId, matrixClient) {
const content = {
body: file.name || 'Attachment',