fix postfix compatiblity

sql is only a standard, ...
master
tuxcoder 2023-12-25 18:57:27 +01:00
parent 0a1da35d84
commit bd7d8e4398
2 changed files with 4 additions and 4 deletions

View File

@ -21,8 +21,8 @@ def upgrade():
op.create_table('passkey_credential',
sa.Column('id', sa.Integer(), autoincrement=True, nullable=False),
sa.Column('user_id', sa.Uuid(), nullable=False),
sa.Column('credential_id', sa.BINARY(), nullable=False),
sa.Column('credential_public_key', sa.BINARY(), nullable=False),
sa.Column('credential_id', sa.LargeBinary(), nullable=False),
sa.Column('credential_public_key', sa.LargeBinary(), nullable=False),
sa.Column('name', sa.String(length=250), nullable=False),
sa.Column('last_used', sa.DateTime(), nullable=True),
sa.Column('sign_count', sa.Integer(), nullable=False),

View File

@ -247,8 +247,8 @@ class PasskeyCredential(BaseModel, ModelUpdatedMixin): # pylint: disable=too-fe
id: Mapped[int] = mapped_column(primary_key=True, autoincrement=True)
user_id: Mapped[uuid.UUID] = mapped_column(db.Uuid, db.ForeignKey('user.id', ondelete='CASCADE'), nullable=False)
credential_id: Mapped[bytes] = mapped_column(db.BINARY, nullable=False)
credential_public_key: Mapped[bytes] = mapped_column(db.BINARY, nullable=False)
credential_id: Mapped[bytes] = mapped_column(db.LargeBinary, nullable=False)
credential_public_key: Mapped[bytes] = mapped_column(db.LargeBinary, nullable=False)
name: Mapped[str] = mapped_column(db.String(250), nullable=False)
last_used: Mapped[Optional[datetime]] = mapped_column(db.DateTime, nullable=True, default=None)
sign_count: Mapped[int] = mapped_column(db.Integer, nullable=False, default=0)