From 6ace23964743eb67ac85bfe7266220f38024bf03 Mon Sep 17 00:00:00 2001 From: sneurlax Date: Thu, 27 Jul 2023 13:11:16 -0500 Subject: [PATCH] check if Exception --- lib/services/cashfusion/connection.dart | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/lib/services/cashfusion/connection.dart b/lib/services/cashfusion/connection.dart index 64780dfba..ee36a17dc 100644 --- a/lib/services/cashfusion/connection.dart +++ b/lib/services/cashfusion/connection.dart @@ -171,7 +171,11 @@ class Connection { }, onError: (e) { subscription?.cancel(); - throw e; + if (e is Exception) { + throw e; + } else { + throw Exception('Unknown error'); + } }, onDone: () { print("DEBUG ON DONE");