WP_Community_Events::maybe_log_events_response()protectedWP 4.8.0

Устарела с версии 4.9.0. Больше не поддерживается и может быть удалена. Смотрите a plugin. See #41217 for an example.

Logs responses to Events API requests.

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

Хуков нет.

Возвращает

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

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

// protected - в коде основоного (родительского) или дочернего класса
$result = $this->maybe_log_events_response( $message, $details );
$message(строка) (обязательный)
A description of what occurred.
$details(массив) (обязательный)
Details that provide more context for the log entry.

Список изменений

С версии 4.8.0 Введена.
Устарела с 4.9.0 Use a plugin instead. See #41217 for an example.

Код WP_Community_Events::maybe_log_events_response() WP 6.5.2

protected function maybe_log_events_response( $message, $details ) {
	_deprecated_function( __METHOD__, '4.9.0' );

	if ( ! WP_DEBUG_LOG ) {
		return;
	}

	error_log(
		sprintf(
			'%s: %s. Details: %s',
			__METHOD__,
			trim( $message, '.' ),
			wp_json_encode( $details )
		)
	);
}