Modified msgtype of send_text & send_html methods
This commit is contained in:
parent
37301597d9
commit
91b2683d65
4
bot.py
4
bot.py
|
@ -73,13 +73,13 @@ class Bot:
|
||||||
async def send_text(self, room, body):
|
async def send_text(self, room, body):
|
||||||
msg = {
|
msg = {
|
||||||
"body": body,
|
"body": body,
|
||||||
"msgtype": "m.text"
|
"msgtype": "m.notice"
|
||||||
}
|
}
|
||||||
await self.client.room_send(room.room_id, 'm.room.message', msg)
|
await self.client.room_send(room.room_id, 'm.room.message', msg)
|
||||||
|
|
||||||
async def send_html(self, room, html, plaintext):
|
async def send_html(self, room, html, plaintext):
|
||||||
msg = {
|
msg = {
|
||||||
"msgtype": "m.text",
|
"msgtype": "m.notice",
|
||||||
"format": "org.matrix.custom.html",
|
"format": "org.matrix.custom.html",
|
||||||
"formatted_body": html,
|
"formatted_body": html,
|
||||||
"body": plaintext
|
"body": plaintext
|
||||||
|
|
Loading…
Reference in New Issue