WP_Customize_Manager::refresh_nonces()publicWP 4.2.0

Refreshes nonces for the current preview.

Method of the class: WP_Customize_Manager{}

No Hooks.

Return

null. Nothing.

Usage

$WP_Customize_Manager = new WP_Customize_Manager();
$WP_Customize_Manager->refresh_nonces();

Changelog

Since 4.2.0 Introduced.

WP_Customize_Manager::refresh_nonces() code WP 6.1.1

public function refresh_nonces() {
	if ( ! $this->is_preview() ) {
		wp_send_json_error( 'not_preview' );
	}

	wp_send_json_success( $this->get_nonces() );
}