ApplicationPasswordEvents final class
Minn\Runtime\ApplicationPasswordEvents · public/minn/src/Minn/Runtime/ApplicationPasswordEvents.php · 46 lines
Application password changes made over REST, as the reference makes them (probe rest-application-password-hooks): the prepared item (the name, and an app id a new one is given) through rest_pre_insert_application_password, then WP_Application_Passwords (which tells plugins through wp_create_, wp_update_ and wp_delete_application_password), then rest_after_insert_application_password.
Public
| static | create(int $userId, array $body, WP_REST_Request $request): WP_Error|array# | A new password: its record and its plain text in groups of four, or the reference's refusal.
@return array{0: array<string, mixed>, 1: string}|\WP_Error | |||
| static | update(int $userId, string $uuid, array $body, WP_REST_Request $request): WP_Error|array# | A password renamed (when the body names it): its record as it stands.
@return array<string, mixed>|\WP_Error |
Internals 1
Private and protected methods: how the class does its work. Not a contract; they change whenever the code is tidied.
| private | prepared(array $fields, WP_REST_Request $request): object# | The item the request prepares (its name; a new one's app id), through rest_pre_insert_application_password. @param array<string, mixed> $fields
|
Nothing matches.