From 44bc641131646010578090d2f101bc14853d5f8a Mon Sep 17 00:00:00 2001 From: Roy Hansen Date: Sat, 24 Jan 2026 11:46:56 +0100 Subject: [PATCH] Bug - When importing csv-transactions, currency_format is not always properly applied. Reparse/tokenize all import lines when changing date/currency formats. In addition, make sure this also happens when setting base_account. --- gnucash/import-export/csv-imp/gnc-import-tx.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/gnucash/import-export/csv-imp/gnc-import-tx.cpp b/gnucash/import-export/csv-imp/gnc-import-tx.cpp index b3c1b32e53..9484e0a26a 100644 --- a/gnucash/import-export/csv-imp/gnc-import-tx.cpp +++ b/gnucash/import-export/csv-imp/gnc-import-tx.cpp @@ -199,12 +199,9 @@ void GncTxImport::base_account (Account* base_account) for (auto line : m_parsed_lines) std::get(line)->set_account (m_settings.m_base_account); } - else - { - /* Reparse all of the lines with the new base account's commodity. */ - tokenize(false); - } + /* Reparse all of the lines with the new base account's commodity. */ + tokenize(false); } } @@ -219,6 +216,9 @@ void GncTxImport::reset_formatted_column (std::vector& col_typ if (col != m_settings.m_column_types.end()) set_column_type (col - m_settings.m_column_types.begin(), col_type, true); } + + /* Reparse all lines */ + tokenize(false); } void GncTxImport::currency_format (int currency_format)