Add default case for switch in ConvertToLocalizedString

This commit is contained in:
Hongxu Xu 2020-11-17 10:08:55 +08:00
commit 98762d2575

View file

@ -286,15 +286,15 @@ String ^ UnitConverterViewModel::ConvertToLocalizedString(const std::wstring& st
switch (cfp)
{
case CurrencyFormatterParameter::Default:
currencyFormatter = m_currencyFormatter;
break;
case CurrencyFormatterParameter::ForValue1:
currencyFormatter = m_currencyFormatter1;
break;
case CurrencyFormatterParameter::ForValue2:
currencyFormatter = m_currencyFormatter2;
break;
default:
currencyFormatter = m_currencyFormatter;
break;
}
// If unit hasn't been set, currencyFormatter1/2 is nullptr. Fallback to default.