Skip to content

Commit 060adf0

Browse files
[flutter_tools] Migrate commands.shard/hermetic/doctor_test to null-safety and make hermetic (#107670)
1 parent bccbcd7 commit 060adf0

File tree

2 files changed

+137
-127
lines changed

2 files changed

+137
-127
lines changed

packages/flutter_tools/lib/src/doctor.dart

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -320,12 +320,12 @@ class Doctor {
320320
Future<bool> diagnose({
321321
bool androidLicenses = false,
322322
bool verbose = true,
323-
bool showColor = true,
324323
AndroidLicenseValidator? androidLicenseValidator,
325324
bool showPii = true,
326325
List<ValidatorTask>? startedValidatorTasks,
327326
bool sendEvent = true,
328327
}) async {
328+
final bool showColor = globals.terminal.supportsColor;
329329
if (androidLicenses && androidLicenseValidator != null) {
330330
return androidLicenseValidator.runLicenseManager();
331331
}
@@ -644,7 +644,7 @@ class DoctorText {
644644

645645
Future<String> _runDiagnosis(bool showPii) async {
646646
try {
647-
await _doctor.diagnose(showColor: false, startedValidatorTasks: _validatorTasks, showPii: showPii, sendEvent: _sendDoctorEvent);
647+
await _doctor.diagnose(startedValidatorTasks: _validatorTasks, showPii: showPii, sendEvent: _sendDoctorEvent);
648648
// Do not send the doctor event a second time.
649649
_sendDoctorEvent = false;
650650
final String text = _logger.statusText;

0 commit comments

Comments
 (0)