tanyapog / travel_list

Checklists for trips and travels
4 stars 0 forks source link

Cast to Null error while saving a trip #38

Open tanyapog opened 2 years ago

tanyapog commented 2 years ago

TripWatcherState.loadFailure(tripFailure: TripFailure.unableToProcess(obj: type 'Null' is not a subtype of type 'Object' in type cast, message: Not acceptable:

tanyapog commented 2 years ago

The problem is in the way I get list of entities (trips or categories) from Firestore. I yeld them in a Stream, but when new entity added, it first sink in this stream with null data, and then, second time, a whole entity. First broken entity provoke type cast error.