You've already forked matrix-react-sdk
mirror of
https://github.com/matrix-org/matrix-react-sdk.git
synced 2025-07-24 06:02:08 +03:00
Send m.sticker messages
This commit is contained in:
@ -275,8 +275,8 @@ class ContentMessages {
|
|||||||
this.nextId = 0;
|
this.nextId = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
sendURLContentToRoom(url, roomId, info, text, matrixClient) {
|
sendStickerContentToRoom(url, roomId, info, text, matrixClient) {
|
||||||
return MatrixClientPeg.get().sendImageMessage(roomId, url, info, text).catch((e) => {
|
return MatrixClientPeg.get().sendStickerMessage(roomId, url, info, text).catch((e) => {
|
||||||
console.warn(`Failed to send content with URL ${url} to room ${roomId}`, e);
|
console.warn(`Failed to send content with URL ${url} to room ${roomId}`, e);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -916,7 +916,7 @@ module.exports = React.createClass({
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
ContentMessages.sendURLContentToRoom(url, this.state.room.roomId, info, text, MatrixClientPeg.get())
|
ContentMessages.sendStickerContentToRoom(url, this.state.room.roomId, info, text, MatrixClientPeg.get())
|
||||||
.done(undefined, (error) => {
|
.done(undefined, (error) => {
|
||||||
if (error.name === "UnknownDeviceError") {
|
if (error.name === "UnknownDeviceError") {
|
||||||
// Let the staus bar handle this
|
// Let the staus bar handle this
|
||||||
|
Reference in New Issue
Block a user