🚑 语法适配到python3.8以上

This commit is contained in:
yajiwa
2023-04-22 21:14:51 +08:00
parent 03cfeb22d8
commit 8c65caf35f
7 changed files with 35 additions and 35 deletions
+2 -2
View File
@@ -29,7 +29,7 @@ class ChatHistory(Model):
@classmethod
async def get_group_msg_rank(
cls,
gid: str | int,
gid: Union[int, str],
limit: int = 10,
order: str = "DESC",
date_scope: Optional[Tuple[datetime, datetime]] = None,
@@ -56,7 +56,7 @@ class ChatHistory(Model):
) # type: ignore
@classmethod
async def get_group_first_msg_datetime(cls, group_id: str | int) -> Optional[datetime]:
async def get_group_first_msg_datetime(cls, group_id: Union[int, str]) -> Optional[datetime]:
"""
说明:
获取群第一条记录消息时间