check null safety for delivery
This commit is contained in:
@@ -25,7 +25,7 @@ class FcsShipmentModel extends BaseModel {
|
||||
notifyListeners();
|
||||
}
|
||||
|
||||
int get selectedIndex => _selectedIndex;
|
||||
int get selectedIndex => _selectedIndex;
|
||||
|
||||
@override
|
||||
void privilegeChanged() {
|
||||
@@ -58,7 +58,8 @@ class FcsShipmentModel extends BaseModel {
|
||||
_fcsShipments.clear();
|
||||
_fcsShipments = snapshot.docs.map((documentSnapshot) {
|
||||
var s = FcsShipment.fromMap(
|
||||
documentSnapshot.data() as Map<String,dynamic>, documentSnapshot.id);
|
||||
documentSnapshot.data() as Map<String, dynamic>,
|
||||
documentSnapshot.id);
|
||||
return s;
|
||||
}).toList();
|
||||
notifyListeners();
|
||||
@@ -108,7 +109,7 @@ class FcsShipmentModel extends BaseModel {
|
||||
.get(const GetOptions(source: Source.server));
|
||||
fcsShipments = snaps.docs.map((documentSnapshot) {
|
||||
var fcs = FcsShipment.fromMap(
|
||||
documentSnapshot.data as Map<String,dynamic>, documentSnapshot.id);
|
||||
documentSnapshot.data as Map<String, dynamic>, documentSnapshot.id);
|
||||
return fcs;
|
||||
}).toList();
|
||||
} catch (e) {
|
||||
@@ -123,7 +124,7 @@ class FcsShipmentModel extends BaseModel {
|
||||
.collection("/$fcs_shipment_collection")
|
||||
.doc(id)
|
||||
.get(const GetOptions(source: Source.server));
|
||||
var fcs = FcsShipment.fromMap(snap.data as Map<String,dynamic>, snap.id);
|
||||
var fcs = FcsShipment.fromMap(snap.data as Map<String, dynamic>, snap.id);
|
||||
|
||||
return fcs;
|
||||
} catch (e) {
|
||||
@@ -141,7 +142,7 @@ class FcsShipmentModel extends BaseModel {
|
||||
.get(const GetOptions(source: Source.server));
|
||||
fcsShipments = snaps.docs.map((documentSnapshot) {
|
||||
var fcs = FcsShipment.fromMap(
|
||||
documentSnapshot.data as Map<String,dynamic>, documentSnapshot.id);
|
||||
documentSnapshot.data as Map<String, dynamic>, documentSnapshot.id);
|
||||
return fcs;
|
||||
}).toList();
|
||||
} catch (e) {
|
||||
|
||||
Reference in New Issue
Block a user