I18N: Use a placeholder instead of the \ character in a translatable string in WP_REST_Users_Controller::check_user_password().

Props ramiy.
Fixes #50812.

git-svn-id: https://develop.svn.wordpress.org/trunk@48692 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Sergey Biryukov 2020-07-30 12:26:45 +00:00
parent e53aaaeead
commit bee24dc17c

View File

@ -1291,7 +1291,11 @@ class WP_REST_Users_Controller extends WP_REST_Controller {
if ( false !== strpos( $password, '\\' ) ) {
return new WP_Error(
'rest_user_invalid_password',
__( 'Passwords cannot contain the "\\" character.' ),
sprintf(
/* translators: %s: The '\' character. */
__( 'Passwords cannot contain the "%s" character.' ),
'\\'
),
array( 'status' => 400 )
);
}