Open thecheebo opened 3 years ago
Use this for the query snapshot: List _brewListFromSnapshot(QuerySnapshot snapshot){ return snapshot.docs.map((doc){ return Brew( name: doc.get('name') ?? '', sugars: doc.get('sugars') ?? '0', strength: doc.get('strength') ?? 0 ); }).toList(); }
Use this for the query snapshot: List _brewListFromSnapshot(QuerySnapshot snapshot){
return snapshot.docs.map((doc){
return Brew(
name: doc.get('name') ?? '',
sugars: doc.get('sugars') ?? '0',
strength: doc.get('strength') ?? 0
);
}).toList();
}