wp_update_application_password хук-событиеWP 5.6.0

Fires when an application password is updated.

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

add_action( 'wp_update_application_password', 'wp_kama_update_application_password_action', 10, 3 );

/**
 * Function for `wp_update_application_password` action-hook.
 * 
 * @param int   $user_id The user ID.
 * @param array $item    The updated application password details.
 * @param array $update  The information to update.
 *
 * @return void
 */
function wp_kama_update_application_password_action( $user_id, $item, $update ){
	// action...
}
$user_id(int)
The user ID.
$item(массив)

The updated application password details.

  • uuid(строка)
    The unique identifier for the application password.

  • app_id(строка)
    A UUID provided by the application to uniquely identify it.

  • name(строка)
    The name of the application password.

  • password(строка)
    A one-way hash of the password.

  • created(int)
    Unix timestamp of when the password was created.

  • last_used(int|null)
    The Unix timestamp of the GMT date the application password was last used.

  • last_ip(строка|null)
    The IP address the application password was last used by.
$update(массив)
The information to update.

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

С версии 5.6.0 Введена.
С версии 6.8.0 The password is now hashed using wp_fast_hash() instead of phpass. Existing passwords may still be hashed using phpass.

Где вызывается хук

WP_Application_Passwords::update_application_password()
wp_update_application_password
wp-includes/class-wp-application-passwords.php 319
do_action( 'wp_update_application_password', $user_id, $item, $update );

Где используется хук в WordPress

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