Move messengers to separate module #3
|
@ -21,14 +21,3 @@ class Matrix:
|
|||
|
||||
async def on_message(self, room, event):
|
||||
print(room, event, file=sys.stderr)
|
||||
|
||||
def upgrade_room(self, room, telegram_nickname):
|
||||
event_dict = nio.event_builders.event_builder.EventBuilder(
|
||||
name=telegram_nickname
|
||||
).as_dict()
|
||||
client.room_send(
|
||||
room_id=room,
|
||||
message_type=event_dict["type"],
|
||||
content=event_dict["content"],
|
||||
) # предположу что оно так работает
|
||||
# https://matrix-nio.readthedocs.io/en/latest/nio.html#module-nio.event_builders.state_events
|
||||
|
|
Reference in a new issue