style(static.py): 更新默认 UA 和请求头

This commit is contained in:
JoeanAmier 2024-12-26 19:30:16 +08:00
parent 10a09b4c0b
commit 14d8ee3abe
2 changed files with 8 additions and 7 deletions

View File

@ -32,9 +32,10 @@ class Download:
"image/png": "png",
"image/jpeg": "jpeg",
"image/webp": "webp",
"application/octet-stream": "",
"video/mp4": "mp4",
"video/quicktime": "mov",
"audio/mp4": "m4a",
"audio/mpeg": "mp3",
}
def __init__(self, manager: Manager, ):

View File

@ -13,14 +13,14 @@ RELEASES = "https://github.com/JoeanAmier/XHS-Downloader/releases/latest"
USERSCRIPT = "https://raw.githubusercontent.com/JoeanAmier/XHS-Downloader/master/static/XHS-Downloader.js"
USERAGENT = ('Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/128.0.0.0 '
'Safari/537.36 Edg/128.0.0.0')
USERAGENT = ("Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/131.0.0.0 "
"Safari/537.36")
HEADERS = {
'accept': 'text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.7',
'cache-control': 'no-cache',
'pragma': 'no-cache',
'user-agent': USERAGENT,
"accept": "text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,"
"application/signed-exchange;v=b3;q=0.7",
"referer": "https://www.xiaohongshu.com/explore",
"user-agent": USERAGENT,
}
MASTER = "b #fff200"