WIP checkpoint: Friends/follow/block models + Alembic migration
This commit is contained in:
@@ -13,7 +13,7 @@ class Block(Base):
|
||||
UniqueConstraint(
|
||||
"blocker_id",
|
||||
"blocked_id",
|
||||
name="uq_blocks_blocker_blocked",
|
||||
name="uq_blocks_pair",
|
||||
),
|
||||
CheckConstraint(
|
||||
"blocker_id <> blocked_id",
|
||||
@@ -39,7 +39,7 @@ class Block(Base):
|
||||
blocker = relationship(
|
||||
"User",
|
||||
foreign_keys=[blocker_id],
|
||||
back_populates="blocks_given",
|
||||
back_populates="blocks_issued",
|
||||
)
|
||||
blocked = relationship(
|
||||
"User",
|
||||
|
||||
Reference in New Issue
Block a user