logging method

void logging(
  1. {required bool on}
)

Turn on logging, true to start, false to stop

Implementation

void logging({required bool on}) {
  MqttLogger.loggingOn = false;
  if (on) {
    MqttLogger.loggingOn = true;
  }
}