mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-09 03:14:30 -04:00
Fixes for tests
This commit is contained in:
parent
1966f00a2d
commit
1cfb2a0ad1
@ -174,7 +174,7 @@ class SubscriptionStatus extends AbstractService
|
|||||||
*/
|
*/
|
||||||
private function checkRefundable(): self
|
private function checkRefundable(): self
|
||||||
{
|
{
|
||||||
if(!$this->recurring_invoice->subscription->refund_period || $this->recurring_invoice->subscription->refund_period === 0) {
|
if(!$this->recurring_invoice->subscription->refund_period || (int)$this->recurring_invoice->subscription->refund_period == 0) {
|
||||||
return $this->setRefundable(false);
|
return $this->setRefundable(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -82,6 +82,9 @@ trait MakesReminders
|
|||||||
|
|
||||||
private function checkEndlessReminder($last_sent_date, $endless_reminder_frequency_id): bool
|
private function checkEndlessReminder($last_sent_date, $endless_reminder_frequency_id): bool
|
||||||
{
|
{
|
||||||
|
if(!$last_sent_date)
|
||||||
|
return false;
|
||||||
|
|
||||||
if (Carbon::now()->startOfDay()->eq($this->addTimeInterval($last_sent_date, $endless_reminder_frequency_id))) {
|
if (Carbon::now()->startOfDay()->eq($this->addTimeInterval($last_sent_date, $endless_reminder_frequency_id))) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user