mirror of
https://github.com/TeamPGM/PagerMaid_Plugins.git
synced 2024-11-22 05:09:15 +00:00
resou weather 修复错误 (#12)
This commit is contained in:
parent
ae2bd7149b
commit
acd3e7a1ef
@ -132,7 +132,7 @@
|
||||
},
|
||||
{
|
||||
"name": "weather",
|
||||
"version": "1.111",
|
||||
"version": "1.112",
|
||||
"section": "daily",
|
||||
"maintainer": "xtaodada",
|
||||
"size": "3.1 kb",
|
||||
@ -142,7 +142,7 @@
|
||||
},
|
||||
{
|
||||
"name": "resou",
|
||||
"version": "1.221",
|
||||
"version": "1.222",
|
||||
"section": "daily",
|
||||
"maintainer": "KorenKrita、xtaodada、monsterxcn",
|
||||
"size": "2.5 kb",
|
||||
|
@ -7,7 +7,7 @@ from pagermaid.utils import Message, client
|
||||
@listener(command="zhrs",
|
||||
description="知乎热搜。")
|
||||
async def zhrs(_: Client, message: Message):
|
||||
req = await client.get("https://tenapi.cn/zhihuresou")
|
||||
req = await client.get("https://tenapi.cn/zhihuresou/")
|
||||
if req.status_code == 200:
|
||||
try:
|
||||
data = req.json()
|
||||
@ -25,7 +25,7 @@ async def zhrs(_: Client, message: Message):
|
||||
@listener(command="wbrs",
|
||||
description="微博热搜。")
|
||||
async def wbrs(_: Client, message: Message):
|
||||
req = await client.get("https://tenapi.cn/resou")
|
||||
req = await client.get("https://tenapi.cn/resou/")
|
||||
if req.status_code == 200:
|
||||
try:
|
||||
data = req.json()
|
||||
@ -44,7 +44,7 @@ async def wbrs(_: Client, message: Message):
|
||||
@listener(command="dyrs",
|
||||
description="抖音热搜。")
|
||||
async def dyrs(_: Client, message: Message):
|
||||
req = await client.get("https://tenapi.cn/douyinresou")
|
||||
req = await client.get("https://tenapi.cn/douyinresou/")
|
||||
if req.status_code == 200:
|
||||
try:
|
||||
data = req.json()
|
||||
|
@ -40,7 +40,7 @@ def calcWindDirection(windDirection):
|
||||
description="查询天气",
|
||||
parameters="<城市>")
|
||||
async def weather(_: Client, message: Message):
|
||||
of not message.arguments:
|
||||
if not message.arguments:
|
||||
return await message.edit("出错了呜呜呜 ~ 无效的参数。")
|
||||
try:
|
||||
req = await client.get(
|
||||
|
Loading…
Reference in New Issue
Block a user