You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
I think there is a problem with the error handling of the function getObjects(). It returns the catched error, which is creating an other exception : 'type 'SocketException' is not a subtype of type 'FutureOr<AlgoliaQuerySnapshot>', as it is trying to cast the error (SocketExcpetion here) into the return type (Future<AlgoliaQuerySnapshot>). My guess is that it would be better to rethrow the error or handling the errors properly.
To Reproduce
Try calling getObjects on a query with no internet connection on the device.
Expected behavior
Throw typed Exceptions, in order to be able to catch the exception with
Dart version: [2.4.0]
Flutter version: [1.7.8+hotfix.3 (stable)]
Algolia Dart Client version : [0.1.6+1]
Describe the bug
I think there is a problem with the error handling of the function getObjects(). It returns the catched error, which is creating an other exception : 'type 'SocketException' is not a subtype of type 'FutureOr<AlgoliaQuerySnapshot>', as it is trying to cast the error (SocketExcpetion here) into the return type (Future<AlgoliaQuerySnapshot>). My guess is that it would be better to rethrow the error or handling the errors properly.
To Reproduce
Try calling getObjects on a query with no internet connection on the device.
Expected behavior
Throw typed Exceptions, in order to be able to catch the exception with
The text was updated successfully, but these errors were encountered: