mirror of
https://github.com/suyiiyii/nonebot-bison.git
synced 2025-06-04 02:26:11 +08:00
update PlatformNoTarget
This commit is contained in:
parent
6bdcdc3242
commit
acd44a1269
@ -260,6 +260,7 @@ class PlatformNoTarget(PlatformProto):
|
||||
return res
|
||||
|
||||
async def fetch_new_post(self, users: list[User]) -> list[tuple[User, list[Post]]]:
|
||||
try:
|
||||
config = Config()
|
||||
post_list = await self.get_sub_list()
|
||||
new_posts = await self.filter_common(post_list)
|
||||
@ -279,3 +280,6 @@ class PlatformNoTarget(PlatformProto):
|
||||
res.append((user, user_post))
|
||||
self.cache = {}
|
||||
return res
|
||||
except httpx.RequestError as err:
|
||||
logger.warning("network connection error: {}, url: {}".format(type(err), err.request.url))
|
||||
return []
|
||||
|
Loading…
x
Reference in New Issue
Block a user