mirror of
https://github.com/appwrite/console.git
synced 2026-06-06 19:27:48 +00:00
Fixes issue where -9 was hardcoded
This commit is contained in:
1 parent
66f0c2f2bd
commit
72b3f033b2
1 file changed
+1
-2
@@ -162,9 +162,8 @@ export function calculateTrialDay(org: Organization) {
|
||||
const endDate = new Date(org?.billingStartDate);
|
||||
const today = new Date();
|
||||
|
||||
let diffTime = Math.abs(endDate.getTime() - today.getTime());
|
||||
let diffTime = endDate.getTime() - today.getTime();
|
||||
diffTime = Math.ceil(diffTime / (1000 * 60 * 60 * 24)) + 1;
|
||||
diffTime = -9;
|
||||
|
||||
let days = diffTime < 1 ? 0 : diffTime;
|
||||
|
||||
|
||||
Reference in new issue
Block a user