Add minimal wrapper around echo in MDOutputHandler that respects

disabling of output
This commit is contained in:
Joshua Ramon Enslin 2023-11-10 03:11:25 +01:00
parent 2024733bba
commit 700bd200ac
Signed by: jrenslin
GPG Key ID: 46016F84501B70AE

View File

@ -35,6 +35,20 @@ final class MDOutputHandler {
/** @var boolean */ /** @var boolean */
private bool $_logfile_status_checked = false; private bool $_logfile_status_checked = false;
/**
* Simple echo that is silent during $disable_completely.
*
* @param string $input Input text.
*
* @return void
*/
public static function echo(string $input):void {
if (self::$disable_completely === true) return;
echo $input;
}
/** /**
* Writes log file contents to log file. * Writes log file contents to log file.
* *