Enable use_if_null_to_convert_nulls_to_bools lint (#98753)
This commit is contained in:
@@ -321,7 +321,7 @@ class VMServiceFlutterDriver extends FlutterDriver {
|
||||
stackTrace,
|
||||
);
|
||||
}
|
||||
if ((response['isError'] as bool?) == true)
|
||||
if ((response['isError'] as bool?) ?? false)
|
||||
throw DriverError('Error in Flutter application: ${response['response']}');
|
||||
return response['response'] as Map<String, dynamic>;
|
||||
}
|
||||
|
||||
@@ -151,7 +151,7 @@ class WebFlutterDriver extends FlutterDriver {
|
||||
final Object? responseData = response['response'];
|
||||
if (isError is! bool?) {
|
||||
throw _createMalformedExtensionResponseError(data);
|
||||
} else if (isError == true) {
|
||||
} else if (isError ?? false) {
|
||||
throw DriverError('Error in Flutter application: $responseData');
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user