mirror of
https://github.com/LiteyukiStudio/nonebot-plugin-acgnshow.git
synced 2025-09-06 12:16:25 +00:00
✨v0.2,不会接受字数大于5的展览查询,添加展览详细信息展示,返回详细错误信息
This commit is contained in:
@ -1,6 +1,7 @@
|
||||
import os
|
||||
import random
|
||||
import datetime
|
||||
import json
|
||||
from pathlib import Path
|
||||
from .config import config
|
||||
|
||||
@ -20,3 +21,8 @@ def convert_timestamp(timestamp) -> str:
|
||||
将时间戳转换为日期格式
|
||||
"""
|
||||
return datetime.datetime.fromtimestamp(timestamp).strftime("%Y-%m-%d %H:%M:%S")
|
||||
|
||||
def extract_banner_url(value) -> str:
|
||||
a = json.loads(value)
|
||||
url = "https:"+a["banner"]["url"]
|
||||
return url
|
Reference in New Issue
Block a user