Yoast_Notification_Center::notification_to_array()privateYoast 3.2

Convert Notification to array representation.

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

Хуков нет.

Возвращает

Массив.

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

// private - только в коде основоного (родительского) класса
$result = $this->notification_to_array( $notification );
$notification(Yoast_Notification) (обязательный)
Notification to convert.

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

С версии 3.2 Введена.

Код Yoast_Notification_Center::notification_to_array() Yoast 22.4

private function notification_to_array( Yoast_Notification $notification ) {

	$notification_data = $notification->to_array();

	if ( isset( $notification_data['nonce'] ) ) {
		unset( $notification_data['nonce'] );
	}

	return $notification_data;
}