mirror of
https://git.mirrors.martin98.com/https://github.com/sub-store-org/Sub-Store.git
synced 2025-08-11 11:28:59 +08:00
fix: 修复重置天数微妙的偏差
This commit is contained in:
parent
4b27d40602
commit
09495fa607
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "sub-store",
|
"name": "sub-store",
|
||||||
"version": "2.14.247",
|
"version": "2.14.248",
|
||||||
"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": {
|
||||||
|
@ -172,6 +172,7 @@ export function getRmainingDays(opt = {}) {
|
|||||||
resetDate.setDate(resetDate.getDate() + cycleDays);
|
resetDate.setDate(resetDate.getDate() + cycleDays);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
resetDate.setHours(0, 0, 0, 0);
|
||||||
const timeDiff = resetDate.getTime() - today.getTime();
|
const timeDiff = resetDate.getTime() - today.getTime();
|
||||||
const daysDiff = Math.ceil(timeDiff / (1000 * 3600 * 24));
|
const daysDiff = Math.ceil(timeDiff / (1000 * 3600 * 24));
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user