similar to what the legacy code does already
profile.markAccountsAsNotPresent(db);
AccountListParser parser = new AccountListParser(resp);
+ ArrayList<LedgerAccount> accountList = new ArrayList<>();
while (true) {
throwIfCancelled();
profile.storeAccountValue(acc.getName(), b.getAcommodity(),
b.getAquantity().asFloat());
}
+
+ accountList.add(acc);
}
throwIfCancelled();
profile.deleteNotPresentAccounts(db);
throwIfCancelled();
db.setTransactionSuccessful();
+ Data.accounts.set(accountList);
}
finally {
db.endTransaction();