diff --git a/cyberwow/lib/controller/rpc.dart b/cyberwow/lib/controller/rpc.dart index 674eb76..1e5f86a 100644 --- a/cyberwow/lib/controller/rpc.dart +++ b/cyberwow/lib/controller/rpc.dart @@ -200,14 +200,19 @@ Future> getTransactionPoolSimple() async { } else { final responseBody = json.decode(response.body); var result = responseBody['transactions']; - result.forEach - ( - (tx) { - tx.remove('tx_blob'); - tx.remove('tx_json'); - tx.remove('last_failed_id_hash'); - } - ); - return result; + if (result == null) { + return []; + } + else { + result.forEach + ( + (tx) { + tx.remove('tx_blob'); + tx.remove('tx_json'); + tx.remove('last_failed_id_hash'); + } + ); + return result; + } } }