ActionScheduler_wpCommentLogger::get_entrypublicWC 1.0

Get single log entry for action.

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

Хуков нет.

Возвращает

ActionScheduler_LogEntry.

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

$ActionScheduler_wpCommentLogger = new ActionScheduler_wpCommentLogger();
$ActionScheduler_wpCommentLogger->get_entry( $entry_id );
$entry_id(строка) (обязательный)
Entry ID.

Код ActionScheduler_wpCommentLogger::get_entry() WC 9.9.5

public function get_entry( $entry_id ) {
	$comment = $this->get_comment( $entry_id );

	if ( empty( $comment ) || self::TYPE !== $comment->comment_type ) {
		return new ActionScheduler_NullLogEntry();
	}

	$date = as_get_datetime_object( $comment->comment_date_gmt );
	ActionScheduler_TimezoneHelper::set_local_timezone( $date );
	return new ActionScheduler_LogEntry( $comment->comment_post_ID, $comment->comment_content, $date );
}