From c2bd49c91ffdab62fa533f759c33f8912422a779 Mon Sep 17 00:00:00 2001
From: Jb Audras
Date: Mon, 24 Apr 2023 16:42:19 +0000
Subject: [PATCH] Coding Standards: Escape edit profile URL in
`default_password_nag()`.
Props utsav72640, mukesh27.
Fixes #58182.
git-svn-id: https://develop.svn.wordpress.org/trunk@55682 602fd350-edb4-49c9-b593-d223f7449a82
---
src/wp-admin/includes/user.php | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/wp-admin/includes/user.php b/src/wp-admin/includes/user.php
index e3a8f6008f..6780824de8 100644
--- a/src/wp-admin/includes/user.php
+++ b/src/wp-admin/includes/user.php
@@ -531,7 +531,7 @@ function default_password_nag() {
echo '' . __( 'Notice:' ) . ' ';
_e( 'You’re using the auto-generated password for your account. Would you like to change it?' );
echo '
';
- printf( '' . __( 'Yes, take me to my profile page' ) . ' | ', get_edit_profile_url() . '#password' );
+ printf( '' . __( 'Yes, take me to my profile page' ) . ' | ', esc_url( get_edit_profile_url() . '#password' ) );
printf( '' . __( 'No thanks, do not remind me again' ) . '', '?default_password_nag=0' );
echo '
';
}