Skip to content

Firefly III: a personal finances manager

Bug fix where the account's balance would be cached when it shouldn't.

James Colef9ab49911dee
diff --git a/app/lib/FireflyIII/Shared/Toolkit/Steam.php b/app/lib/FireflyIII/Shared/Toolkit/Steam.php
index 248ae8d9cd..d1d0c9e0cd 100644
--- a/app/lib/FireflyIII/Shared/Toolkit/Steam.php
+++ b/app/lib/FireflyIII/Shared/Toolkit/Steam.php
@@ -29,7 +29,8 @@ class Steam
$key = 'account.' . $account->id . '.balanceOn' . $date->format('dmy');
}
if (\Cache::has($key)) {
- return \Cache::get($key);
+ // TODO find a way to reliably remove cache entries for accounts.
+ #return \Cache::get($key);
}
$date = is_null($date) ? Carbon::now() : $date;
$balance = floatval(
diff --git a/bootstrap/start.php b/bootstrap/start.php
index 17521dbcf5..1d6083d86d 100644
--- a/bootstrap/start.php
+++ b/bootstrap/start.php
@@ -95,12 +95,14 @@ require $framework . '/Illuminate/Foundation/start.php';
//Event::subscribe('Firefly\Trigger\Budgets\EloquentBudgetTrigger');
//Event::subscribe('Firefly\Trigger\Recurring\EloquentRecurringTrigger');
//Event::subscribe('Firefly\Trigger\Journals\EloquentJournalTrigger');
-Event::subscribe('FireflyIII\Event\Piggybank');
-Event::subscribe('FireflyIII\Event\Budget');
-Event::subscribe('FireflyIII\Event\TransactionJournal');
-Event::subscribe('FireflyIII\Event\Transaction');
+
Event::subscribe('FireflyIII\Event\Account');
+Event::subscribe('FireflyIII\Event\Budget');
Event::subscribe('FireflyIII\Event\Event');
+Event::subscribe('FireflyIII\Event\Piggybank');
+Event::subscribe('FireflyIII\Event\Transaction');
+Event::subscribe('FireflyIII\Event\TransactionJournal');
+
// event that creates a relationship between transaction journals and recurring events when created.
// event that updates the relationship between transaction journals and recurring events when edited.