mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-07 15:34:39 -04:00
Sending reminders command: Trying to get property of non-object #1806
This commit is contained in:
parent
9d1cb37835
commit
ee03ae7003
@ -1208,9 +1208,14 @@ class InvoiceRepository extends BaseRepository
|
|||||||
|
|
||||||
public function findNeedingEndlessReminding(Account $account)
|
public function findNeedingEndlessReminding(Account $account)
|
||||||
{
|
{
|
||||||
$frequencyId = $account->account_email_settings->frequency_id_reminder4;
|
$settings = $account->account_email_settings;
|
||||||
$frequency = Utils::getFromCache($frequencyId, 'frequencies');
|
$frequencyId = $settings->frequency_id_reminder4;
|
||||||
|
|
||||||
|
if (! $frequencyId || ! $account->enable_reminder4) {
|
||||||
|
return [];
|
||||||
|
}
|
||||||
|
|
||||||
|
$frequency = Utils::getFromCache($frequencyId, 'frequencies');
|
||||||
$lastSentDate = date_create();
|
$lastSentDate = date_create();
|
||||||
$lastSentDate->sub(date_interval_create_from_date_string($frequency->date_interval));
|
$lastSentDate->sub(date_interval_create_from_date_string($frequency->date_interval));
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user