mirror of
https://git.mirrors.martin98.com/https://github.com/sub-store-org/Sub-Store.git
synced 2025-07-31 22:51:59 +08:00
feat: 支持更多的 subscription-userinfo
This commit is contained in:
parent
f4639d9a34
commit
56fd495fb6
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "sub-store",
|
"name": "sub-store",
|
||||||
"version": "2.14.416",
|
"version": "2.14.417",
|
||||||
"description": "Advanced Subscription Manager for QX, Loon, Surge, Stash and ShadowRocket.",
|
"description": "Advanced Subscription Manager for QX, Loon, Surge, Stash and ShadowRocket.",
|
||||||
"main": "src/main.js",
|
"main": "src/main.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
|
@ -198,12 +198,18 @@ export function parseFlowHeaders(flowHeaders) {
|
|||||||
const appUrlMatch = flowHeaders.match(/app_url=(.*?)\s*?(;|$)/);
|
const appUrlMatch = flowHeaders.match(/app_url=(.*?)\s*?(;|$)/);
|
||||||
const appUrl = appUrlMatch ? appUrlMatch[1] : undefined;
|
const appUrl = appUrlMatch ? appUrlMatch[1] : undefined;
|
||||||
|
|
||||||
|
const planNameMatch = flowHeaders.match(/plan_name=(.*?)\s*?(;|$)/);
|
||||||
|
const planName = planNameMatch
|
||||||
|
? decodeURIComponent(planNameMatch[1])
|
||||||
|
: undefined;
|
||||||
|
|
||||||
return {
|
return {
|
||||||
expires,
|
expires,
|
||||||
total,
|
total,
|
||||||
usage: { upload, download },
|
usage: { upload, download },
|
||||||
remainingDays,
|
remainingDays,
|
||||||
appUrl,
|
appUrl,
|
||||||
|
planName,
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user