fix #47, fix weibo fulltext

This commit is contained in:
felinae98
2022-04-30 00:46:52 +08:00
parent e7d5018481
commit 167d577141
6 changed files with 85 additions and 83 deletions
@@ -47,7 +47,7 @@ class Bilibili(NewMessage):
)
res_dict = json.loads(res.text)
if res_dict["code"] == 0:
return res_dict["data"]["cards"]
return res_dict["data"].get("cards")
else:
return []
+1 -1
View File
@@ -130,7 +130,7 @@ class Weibo(NewMessage):
)
try:
full_json_text = re.search(
r'"status": ([\s\S]+),\s+"hotScheme"', res.text
r'"status": ([\s\S]+),\s+"call"', res.text
).group(1)
info = json.loads(full_json_text)
except: