compare lower case currency titles

Godwin Asuquo committed Jan 31, 2022 at 13:54 UTC 489f15b8072a068a27ca14d98f32414dfaee9f28
1 file changed +4 -1
lib/view_model/send/send_view_model.dart
+4 -1
@@ -131,7 +131,7 @@ abstract class SendViewModelBase with Store {
131
132 @computed
133 List<Template> get templates => sendTemplateViewModel.templates
134 - .where((template) => template.cryptoCurrency == _wallet.currency.title)
134 + .where((template) => _isEqualCurrency(template.cryptoCurrency))
135 .toList();
136
137 @computed
@@ -231,4 +231,7 @@ abstract class SendViewModelBase with Store {
231
232 return priority.toString();
233 }
234 +
235 + bool _isEqualCurrency(String currency) =>
236 + currency.toLowerCase() == _wallet.currency.title.toLowerCase();
237 }