2022-02-25 02:22:50 -05:00
|
|
|
from mautrix.util.async_db import Database
|
|
|
|
|
|
|
|
from .message import Message
|
|
|
|
from .portal import Portal
|
|
|
|
from .puppet import Puppet
|
|
|
|
from .upgrade import upgrade_table
|
|
|
|
from .user import User
|
|
|
|
|
|
|
|
|
|
|
|
def init(db: Database) -> None:
|
2022-04-10 23:05:43 -04:00
|
|
|
for table in (Portal, Message, User, Puppet):
|
2022-02-25 02:22:50 -05:00
|
|
|
table.db = db
|
|
|
|
|
|
|
|
|
|
|
|
__all__ = [
|
|
|
|
"upgrade_table",
|
|
|
|
"init",
|
|
|
|
"Message",
|
|
|
|
"Portal",
|
|
|
|
"ThreadType",
|
|
|
|
"Puppet",
|
|
|
|
"User",
|
|
|
|
]
|