mirror of
https://github.com/Such-Software/hash-wallet.git
synced 2026-10-19 05:58:50 +02:00
enhance exception handling in cakePay getVendors (#1833)
This commit is contained in:
@@ -233,7 +233,8 @@ class CakePayApi {
|
||||
var response = await http.get(uri, headers: headers);
|
||||
|
||||
if (response.statusCode != 200) {
|
||||
throw Exception(response.body);
|
||||
throw Exception(
|
||||
'Failed to fetch vendors: statusCode - ${response.statusCode}, queryParams -$queryParams, response - ${response.body}');
|
||||
}
|
||||
|
||||
final bodyJson = json.decode(response.body);
|
||||
|
||||
@@ -94,6 +94,10 @@ class CakePayCardsPage extends BasePage {
|
||||
_cardsListViewModel.resetLoadingNextPageState();
|
||||
_cardsListViewModel.getVendors();
|
||||
}
|
||||
|
||||
_cardsListViewModel.settingsStore.selectedCakePayCountry =
|
||||
_cardsListViewModel.selectedCountry;
|
||||
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user