Enable null_closures (#77095)

This commit is contained in:
Michael Goderbauer 2021-03-02 15:25:31 -08:00 committed by GitHub
parent 7e017d318e
commit ea8e61618a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 5 additions and 5 deletions

View file

@ -134,7 +134,7 @@ linter:
# - no_runtimeType_toString # ok in tests; we enable this only in packages/
- non_constant_identifier_names
- null_check_on_nullable_type_parameter
# - null_closures # not required by flutter style
- null_closures
# - omit_local_variable_types # opposite of always_specify_types
# - one_member_abstracts # too many false positives
# - only_throw_errors # https://github.com/flutter/flutter/issues/5792

View file

@ -227,7 +227,7 @@ class MotionEventsBodyState extends State<MotionEventsBody> {
setState(() {});
break;
}
return Future<dynamic>.sync(null);
return Future<dynamic>.value(null);
}
Future<dynamic> onViewMethodChannelCall(MethodCall call) {
@ -240,7 +240,7 @@ class MotionEventsBodyState extends State<MotionEventsBody> {
setState(() {});
break;
}
return Future<dynamic>.sync(null);
return Future<dynamic>.value(null);
}
Widget buildEventTile(BuildContext context, int index) {

View file

@ -199,7 +199,7 @@ class MotionEventsBodyState extends State<MotionEventsBody> {
setState(() {});
break;
}
return Future<dynamic>.sync(null);
return Future<dynamic>.value(null);
}
Future<dynamic> onViewMethodChannelCall(MethodCall call) {
@ -212,7 +212,7 @@ class MotionEventsBodyState extends State<MotionEventsBody> {
setState(() {});
break;
}
return Future<dynamic>.sync(null);
return Future<dynamic>.value(null);
}
Widget buildEventTile(BuildContext context, int index) {