CsvPriceImp - change a few translatable strings to match the once in CsvTxImp

Saves translators a few cycles.
This commit is contained in:
Geert Janssens 2023-02-17 14:15:59 +01:00
parent 64329414e9
commit ea60687524

View File

@ -234,17 +234,17 @@ void GncImportPrice::set (GncPricePropType prop_type, const std::string& value,
}
catch (const std::invalid_argument& e)
{
auto err_str = (bl::format (std::string{_("Column '{1}' could not be understood.\n")}) %
std::string{_(gnc_price_col_type_strs[prop_type])}).str() +
e.what();
auto err_str = (bl::format (std::string{_("{1}: {2}")}) %
std::string{_(gnc_price_col_type_strs[prop_type])} %
e.what()).str();
m_errors.emplace(prop_type, err_str);
throw std::invalid_argument (err_str);
}
catch (const std::out_of_range& e)
{
auto err_str = (bl::format (std::string{_("Column '{1}' could not be understood.\n")}) %
std::string{_(gnc_price_col_type_strs[prop_type])}).str() +
e.what();
auto err_str = (bl::format (std::string{_("{1}: {2}")}) %
std::string{_(gnc_price_col_type_strs[prop_type])} %
e.what()).str();
m_errors.emplace(prop_type, err_str);
throw std::invalid_argument (err_str);
}