ACF_UI_Options_Page::value_was_saved_prior_to_icon_picker_field │ public │ ACF 6.3

This function returns whether the value was saved prior to the icon picker field or not.

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

Хуков нет.

Возвращает

boolean.

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

$ACF_UI_Options_Page = new ACF_UI_Options_Page();
$ACF_UI_Options_Page->value_was_saved_prior_to_icon_picker_field( $args );
$args(разное) (обязательный)
The args for the icon field.

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

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

Код ACF_UI_Options_Page::value_was_saved_prior_to_icon_picker_field() ACF 6.8.8

public function value_was_saved_prior_to_icon_picker_field( $args ) {
	if (
		! empty( $args['menu_icon'] ) &&
		is_array( $args['menu_icon'] ) &&
		! empty( $args['menu_icon']['type'] ) &&
		! empty( $args['menu_icon']['value'] )
	) {
		return false;
	}

	return true;
}