File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -19,7 +19,7 @@ import { ObjectId } from 'mongodb';
1919import * as path from 'path' ;
2020import * as dotenv from 'dotenv' ;
2121import { HttpStatusCode } from '../../../lib/utils/consts' ;
22- import { daysAfterPayday } from '../../../lib/utils/payday' ;
22+ import { countDaysAfterPayday } from '../../../lib/utils/payday' ;
2323
2424/**
2525 * Merge email worker .env and root workers .env
@@ -148,7 +148,7 @@ class EmailTestServer {
148148 user,
149149 period : 10 ,
150150 reason : 'error on the payment server side' ,
151- daysAfterPayday : await this . calculateDaysAfterPayday ( workspace ) ,
151+ daysAfterPayday : countDaysAfterPayday ( workspace . lastChargeDate , workspace . paidUntil ) ,
152152 } ;
153153
154154 try {
@@ -339,7 +339,7 @@ class EmailTestServer {
339339 return 0 ;
340340 }
341341
342- const days = daysAfterPayday ( workspace . lastChargeDate , workspace . paidUntil ) ;
342+ const days = countDaysAfterPayday ( workspace . lastChargeDate , workspace . paidUntil ) ;
343343
344344 return days > 0 ? days : 0 ;
345345 }
You can’t perform that action at this time.
0 commit comments