phase3: nullfix.py batch script — bang/late/param-nullable
Automated null-safety fixes driven by dart analyze (no corruption): - unchecked_use_of_nullable_value: insert '!' on receiver (property/method/[]/op) - not_initialized field/var: mark 'late' - missing_default_value_for_parameter: nullable param Errors: 2374(peak) -> 907
This commit is contained in:
@@ -32,13 +32,13 @@ class Shop extends StatefulWidget {
|
||||
}
|
||||
|
||||
class ShopState extends State<Shop> {
|
||||
Business _business;
|
||||
late Business _business;
|
||||
|
||||
PanelController panelController = PanelController();
|
||||
SlidingUpPanel _slidUpShoppingCart;
|
||||
late SlidingUpPanel _slidUpShoppingCart;
|
||||
GlobalKey endKey = GlobalKey();
|
||||
|
||||
List<CategoryProducts> _categoryProducts;
|
||||
late List<CategoryProducts> _categoryProducts;
|
||||
bool displayProductByCategoryClick = false;
|
||||
String displayProductByCategoryClickIndicator = '';
|
||||
int categoryId = 0;
|
||||
@@ -261,7 +261,7 @@ class ShopState extends State<Shop> {
|
||||
if (moreCategoryProducts.isEmpty) {
|
||||
_productCurrentPage = 0;
|
||||
} else {
|
||||
if (moreCategoryProducts[0].products.length < Constants.ORDERS_PER_PAGE) {
|
||||
if (moreCategoryProducts[0].products!.length < Constants.ORDERS_PER_PAGE) {
|
||||
_productCurrentPage = 0;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user