Kumi
5b500d34b5
Automatically accept room invites on sync Leave rooms if everyone else leaves README update !gptbot dice command Minor fixes
32 lines
No EOL
706 B
Python
32 lines
No EOL
706 B
Python
from nio import (
|
|
RoomMessageText,
|
|
MegolmEvent,
|
|
InviteEvent,
|
|
Event,
|
|
SyncResponse,
|
|
JoinResponse,
|
|
InviteEvent,
|
|
OlmEvent,
|
|
MegolmEvent,
|
|
RoomMemberEvent,
|
|
)
|
|
|
|
from .test import test_callback
|
|
from .sync import sync_callback
|
|
from .invite import room_invite_callback
|
|
from .join import join_callback
|
|
from .message import message_callback
|
|
from .roommember import roommember_callback
|
|
|
|
RESPONSE_CALLBACKS = {
|
|
SyncResponse: sync_callback,
|
|
JoinResponse: join_callback,
|
|
}
|
|
|
|
EVENT_CALLBACKS = {
|
|
Event: test_callback,
|
|
InviteEvent: room_invite_callback,
|
|
RoomMessageText: message_callback,
|
|
MegolmEvent: message_callback,
|
|
RoomMemberEvent: roommember_callback,
|
|
} |