]> git.ktnx.net Git - mobile-ledger.git/commitdiff
drop improper list copy
authorDamyan Ivanov <dam+mobileledger@ktnx.net>
Thu, 4 Mar 2021 21:21:07 +0000 (23:21 +0200)
committerDamyan Ivanov <dam+mobileledger@ktnx.net>
Thu, 4 Mar 2021 21:21:07 +0000 (23:21 +0200)
1) the list shall be copied only when the original is the live list
2) a (proper) list copy is made just a couple of lines earlier

app/src/main/java/net/ktnx/mobileledger/ui/new_transaction/NewTransactionModel.java

index 825f148ad91f95a759053ae32ff87a0fc5d711b7..707bc089cdf14ef3918ad74af4f7ea118f165aae 100644 (file)
@@ -641,10 +641,6 @@ public class NewTransactionModel extends ViewModel {
                                 }
                                 final TransactionAccount newAcc = new TransactionAccount(acc);
                                 newAcc.setAmountHint(null);
-                                if (!liveListCopied) {
-                                    list = copyList(list);
-                                    liveListCopied = true;
-                                }
                                 list.set(i, newAcc);
                                 listChanged = true;
                             }