public static function init($os_type = '', $mode, $is_debug) { self::$log_path = BP . DS . self::$app_log_dir; if (!file_exists(self::$log_path)) { mkdir(self::$log_path); } if ($os_type == "WIN") { self::$is_colored_glob = false; } if ($mode == 'CLOUD' && $is_debug == false) { self::$is_write = false; } }
public static function init($mode, $is_debug, $os_type = '') { self::$log_path = BP . DS . self::$app_log_dir; if (!file_exists(self::$log_path)) { mkdir(self::$log_path); } if ($os_type == "WIN") { self::$is_colored_glob = false; } if ($mode == 'CLOUD' && $is_debug == false) { self::$is_write = false; // in cloud mode do not write log if debug mode switch off } if ($mode == 'CLOUD' && $is_debug == true) { self::$redirect_to_stdout = true; //if in cloud mode switch on debug mode write all log to stdout } }