diff --git a/app/Services/Internal/Update/AccountUpdateService.php b/app/Services/Internal/Update/AccountUpdateService.php index 51add15fba..1e92b4a4a2 100644 --- a/app/Services/Internal/Update/AccountUpdateService.php +++ b/app/Services/Internal/Update/AccountUpdateService.php @@ -325,7 +325,7 @@ class AccountUpdateService if ($this->validOBData($data) && !$this->isEmptyOBData($data)) { $openingBalance = $data['opening_balance']; $openingBalanceDate = $data['opening_balance_date']; - if ('credit' === $data['liability_direction']) { + if ('credit' === $direction) { $this->updateCreditTransaction($account, $openingBalance, $openingBalanceDate); } }