Yoast\WP\SEO\Bulk_Editor\Application\Updates

Bulk_Updater::sanitized_fields │ private │ Yoast 1.0

Builds the sanitized-literals payload for the response.

The focus keyphrase is echoed back when it was part of the update, so the frontend can detect when sanitization silently altered the submitted value (e.g. HTML stripped).

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

Хуков нет.

Возвращает

array<string, string>. The sanitized literals, keyed by field.

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

// private - только в коде основоного (родительского) класса
$result = $this->sanitized_fields( ?string $saved_focus_keyphrase ): array;
?string $saved_focus_keyphrase(обязательный)
.

Код Bulk_Updater::sanitized_fields() Yoast 28.9

private function sanitized_fields( ?string $saved_focus_keyphrase ): array {
	if ( $saved_focus_keyphrase === null ) {
		return [];
	}

	return [ 'focus_keyphrase' => $saved_focus_keyphrase ];
}