mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-12-12 01:42:32 +00:00
Fix #11281 and some other stuff.
This commit is contained in:
@@ -24,6 +24,7 @@ declare(strict_types=1);
|
||||
|
||||
namespace FireflyIII\Services\Internal\Update;
|
||||
|
||||
use FireflyIII\Support\Facades\Preferences;
|
||||
use Illuminate\Support\Facades\Log;
|
||||
use FireflyIII\Enums\AccountTypeEnum;
|
||||
use FireflyIII\Events\UpdatedAccount;
|
||||
@@ -291,7 +292,7 @@ class AccountUpdateService
|
||||
if (true === $account->active) {
|
||||
return;
|
||||
}
|
||||
$preference = app('preferences')->getForUser($account->user, 'frontpageAccounts');
|
||||
$preference = Preferences::getForUser($account->user, 'frontpageAccounts');
|
||||
if (null === $preference) {
|
||||
return;
|
||||
}
|
||||
@@ -310,6 +311,6 @@ class AccountUpdateService
|
||||
}
|
||||
}
|
||||
Log::debug('Final new array is', $new);
|
||||
app('preferences')->setForUser($account->user, 'frontpageAccounts', $new);
|
||||
Preferences::setForUser($account->user, 'frontpageAccounts', $new);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -24,6 +24,7 @@ declare(strict_types=1);
|
||||
|
||||
namespace FireflyIII\Services\Internal\Update;
|
||||
|
||||
use FireflyIII\Support\Facades\Preferences;
|
||||
use FireflyIII\Events\TriggeredAuditLog;
|
||||
use FireflyIII\Exceptions\DuplicateTransactionException;
|
||||
use FireflyIII\Exceptions\FireflyException;
|
||||
@@ -83,7 +84,7 @@ class GroupUpdateService
|
||||
$this->updateTransactionJournal($transactionGroup, $first, reset($transactions));
|
||||
$transactionGroup->touch();
|
||||
$transactionGroup->refresh();
|
||||
app('preferences')->mark();
|
||||
Preferences::mark();
|
||||
|
||||
return $transactionGroup;
|
||||
}
|
||||
@@ -98,7 +99,7 @@ class GroupUpdateService
|
||||
Log::error('There were no transactions updated or created. Will not delete anything.');
|
||||
$transactionGroup->touch();
|
||||
$transactionGroup->refresh();
|
||||
app('preferences')->mark();
|
||||
Preferences::mark();
|
||||
|
||||
return $transactionGroup;
|
||||
}
|
||||
@@ -116,7 +117,7 @@ class GroupUpdateService
|
||||
$service->destroy($journal);
|
||||
}
|
||||
|
||||
app('preferences')->mark();
|
||||
Preferences::mark();
|
||||
$transactionGroup->touch();
|
||||
$transactionGroup->refresh();
|
||||
|
||||
|
||||
@@ -24,6 +24,7 @@ declare(strict_types=1);
|
||||
|
||||
namespace FireflyIII\Services\Internal\Update;
|
||||
|
||||
use FireflyIII\Support\Facades\Preferences;
|
||||
use Carbon\Carbon;
|
||||
use Carbon\Exceptions\InvalidDateException;
|
||||
use Carbon\Exceptions\InvalidFormatException;
|
||||
@@ -165,7 +166,7 @@ class JournalUpdateService
|
||||
$this->updateAmount();
|
||||
$this->updateForeignAmount();
|
||||
|
||||
app('preferences')->mark();
|
||||
Preferences::mark();
|
||||
|
||||
$this->transactionJournal->refresh();
|
||||
Log::debug('Done with update journal routine');
|
||||
|
||||
Reference in New Issue
Block a user