fix: 修复聚合模式下,名称带有中文或特殊符号的分享token判断异常的问题

This commit is contained in:
Aritro37 2025-03-20 21:57:42 +08:00 committed by GitHub
parent 5696492dde
commit c5d8aff73c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 2 additions and 2 deletions

View File

@ -1,6 +1,6 @@
{
"name": "sub-store",
"version": "2.19.0",
"version": "2.19.1",
"description": "Advanced Subscription Manager for QX, Loon, Surge, Stash and Shadowrocket.",
"main": "src/main.js",
"scripts": {

View File

@ -54,7 +54,7 @@ export default function serve() {
next();
return;
}
const pathname = req._parsedUrl.pathname || '/';
const pathname = decodeURIComponent(req._parsedUrl.pathname) || '/';
if(be_merge && req.path.startsWith('/share/') && req.query.token){
if (req.method.toLowerCase() !== 'get'){
res.status(405).send('Method not allowed');