WC_Log_Handler_Email::add_log()protectedWC 1.0

Add log message.

Метод класса: WC_Log_Handler_Email{}

Хуков нет.

Возвращает

null. Ничего (null).

Использование

// protected - в коде основоного (родительского) или дочернего класса
$result = $this->add_log( $timestamp, $level, $message, $context );
$timestamp(int) (обязательный)
Log timestamp.
$level(строка) (обязательный)
emergency|alert|critical|error|warning|notice|info|debug.
$message(строка) (обязательный)
Log message.
$context(массив) (обязательный)
Additional information for log handlers.

Код WC_Log_Handler_Email::add_log() WC 8.7.0

protected function add_log( $timestamp, $level, $message, $context ) {
	$this->logs[] = $this->format_entry( $timestamp, $level, $message, $context );

	$log_severity = WC_Log_Levels::get_level_severity( $level );
	if ( $this->max_severity < $log_severity ) {
		$this->max_severity = $log_severity;
	}
}