mirror of
https://github.com/maubot/maubot
synced 2025-09-07 01:30:38 +00:00
Add device_id to client db
This commit is contained in:
parent
9578883bbb
commit
09108f6a73
6 changed files with 47 additions and 10 deletions
|
@ -21,7 +21,7 @@ from sqlalchemy import Column, String, Boolean, ForeignKey, Text
|
|||
from sqlalchemy.engine.base import Engine
|
||||
import sqlalchemy as sql
|
||||
|
||||
from mautrix.types import UserID, FilterID, SyncToken, ContentURI
|
||||
from mautrix.types import UserID, FilterID, DeviceID, SyncToken, ContentURI
|
||||
from mautrix.util.db import Base
|
||||
|
||||
from .config import Config
|
||||
|
@ -53,6 +53,7 @@ class DBClient(Base):
|
|||
id: UserID = Column(String(255), primary_key=True)
|
||||
homeserver: str = Column(String(255), nullable=False)
|
||||
access_token: str = Column(Text, nullable=False)
|
||||
device_id: DeviceID = Column(String(255), nullable=True)
|
||||
enabled: bool = Column(Boolean, nullable=False, default=False)
|
||||
|
||||
next_batch: SyncToken = Column(String(255), nullable=False, default="")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue