From 64ecf03841680fd8e00636b667a66362f7968b56 Mon Sep 17 00:00:00 2001 From: Dario Rekowski on RockPI Date: Thu, 13 May 2021 11:25:24 +0000 Subject: [PATCH] truncate state balances for migration --- community_server/src/Controller/MigrationsController.php | 1 + community_server/src/Model/Table/StateBalancesTable.php | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/community_server/src/Controller/MigrationsController.php b/community_server/src/Controller/MigrationsController.php index 31fa41001..97481aff5 100644 --- a/community_server/src/Controller/MigrationsController.php +++ b/community_server/src/Controller/MigrationsController.php @@ -64,6 +64,7 @@ class MigrationsController extends AppController $commands = [ [$blockchainTypesTable, 'fillWithDefault'], [$transactionTypesTable, 'fillWithDefault'], + [$stateBalancesTable, 'truncate'], [$transactionsTable, 'fillStateUserTransactions'], [$stateBalancesTable, 'updateAllBalances'] ]; diff --git a/community_server/src/Model/Table/StateBalancesTable.php b/community_server/src/Model/Table/StateBalancesTable.php index 7e5f96be9..25d588f30 100644 --- a/community_server/src/Model/Table/StateBalancesTable.php +++ b/community_server/src/Model/Table/StateBalancesTable.php @@ -24,7 +24,7 @@ use Cake\I18n\FrozenTime; * * @mixin \Cake\ORM\Behavior\TimestampBehavior */ -class StateBalancesTable extends Table +class StateBalancesTable extends AppTable { private static $startDecayDate = null; /**