wpseek.com
Outil de recherche WordPress pour les développeurs et auteurs de thèmes



rest_add_application_passwords_to_index › WordPress Function

Depuis5.6.0
Dépréciéen/a
rest_add_application_passwords_to_index ( $response )
Paramètres:
  • (WP_REST_Response) $response The index response object.
    Requis: Oui
Retourne:
  • (WP_REST_Response)
Défini(e) dans:
Codex:

Adds Application Passwords info to the REST API index.



Source

function rest_add_application_passwords_to_index( $response ) {
	if ( ! wp_is_application_passwords_available() ) {
		return $response;
	}

	$response->data['authentication']['application-passwords'] = array(
		'endpoints' => array(
			'authorization' => admin_url( 'authorize-application.php' ),
		),
	);

	return $response;
}