setPower method Null safety

Future<void> setPower(
  1. bool on
)

Implementation

Future<void> setPower(bool on) async {
  if (on) {
    await wake();
  } else {
    await sendKey(_powerKey);
  }
}