check null safety
This commit is contained in:
@@ -1,5 +1,4 @@
|
||||
import 'package:fcs/domain/entities/cargo_type.dart';
|
||||
import 'package:fcs/domain/entities/custom_duty.dart';
|
||||
import 'package:fcs/domain/entities/discount_by_weight.dart';
|
||||
import 'package:fcs/domain/entities/rate.dart';
|
||||
import 'package:fcs/helpers/theme.dart';
|
||||
@@ -185,8 +184,8 @@ class _ShipmentRatesState extends State<ShipmentRates> {
|
||||
List<Widget> getCargoWidget(List<CargoType> cargos) {
|
||||
return cargos.map((cargo) {
|
||||
return Container(
|
||||
child: _row(
|
||||
cargo.name, "\$ " + cargo.rate.toStringAsFixed(2), 'per pound'),
|
||||
child: _row(cargo.name ?? "", "\$ " + cargo.rate.toStringAsFixed(2),
|
||||
'per pound'),
|
||||
);
|
||||
}).toList();
|
||||
}
|
||||
@@ -194,7 +193,8 @@ class _ShipmentRatesState extends State<ShipmentRates> {
|
||||
List<Widget> getCustonWidget(List<CargoType> customs) {
|
||||
return customs.map((c) {
|
||||
return Container(
|
||||
child: _row(c.name, "\$ " + c.customDutyFee.toStringAsFixed(2), ''),
|
||||
child:
|
||||
_row(c.name ?? "", "\$ " + c.customDutyFee.toStringAsFixed(2), ''),
|
||||
);
|
||||
}).toList();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user