From 922050a79bb79f2461555a297947deedb08a0542 Mon Sep 17 00:00:00 2001 From: James Cole Date: Sat, 27 Mar 2021 15:28:11 +0100 Subject: [PATCH] Should be enough to fix order issues. --- app/Repositories/Account/AccountRepository.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/app/Repositories/Account/AccountRepository.php b/app/Repositories/Account/AccountRepository.php index 0e0529f081..60e454d222 100644 --- a/app/Repositories/Account/AccountRepository.php +++ b/app/Repositories/Account/AccountRepository.php @@ -630,6 +630,10 @@ class AccountRepository implements AccountRepositoryInterface $list = $this->getAccountsByType($set); $index = 1; foreach ($list as $account) { + if(false === $account->active) { + $account->order = 0; + continue; + } if ($index !== (int)$account->order) { Log::debug(sprintf('Account #%d ("%s"): order should %d be but is %d.', $account->id, $account->name, $index, $account->order)); $account->order = $index;