mai2: fix presents
This commit is contained in:
1 parent
e9afaaf56c
commit
af8bd1d1c0
3 files changed
+11
-5
No files matched your search
@@ -635,10 +635,10 @@ class Mai2ItemData(BaseData):
|
||||
async def get_presents_by_version_user(self, ver: int = None, user_id: int = None) -> Optional[List[Row]]:
|
||||
result = await self.execute(present.select(
|
||||
and_(
|
||||
or_(present.c.user == user_id, present.c.user is None)),
|
||||
or_(present.c.version == ver, present.c.version is None)
|
||||
or_(present.c.user == user_id, present.c.user == None),
|
||||
or_(present.c.version == ver, present.c.version == None)
|
||||
)
|
||||
)
|
||||
))
|
||||
if result:
|
||||
return result.fetchall()
|
||||
|
||||
|
||||
Reference in new issue
Block a user