mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-06-28 22:30:04 +00:00
Users: Remove password reset links when the feature is not allowed for a specific user.
This also introduces `wp_is_password_reset_allowed_for_user()` which returns `false` when password reset is not allowed for a specific user. This can be filtered by developers using the existing `allow_password_reset` hook. Props ocean90, cshark, robinwpdeveloper, tahmina1du, kraftbj. Fixes #58194. git-svn-id: https://develop.svn.wordpress.org/trunk@56150 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -681,7 +681,7 @@ switch ( $action ) {
|
||||
<?php endif; // End Show Password Fields. ?>
|
||||
|
||||
<?php // Allow admins to send reset password link. ?>
|
||||
<?php if ( ! IS_PROFILE_PAGE ) : ?>
|
||||
<?php if ( ! IS_PROFILE_PAGE && true === wp_is_password_reset_allowed_for_user( $profile_user ) ) : ?>
|
||||
<tr class="user-generate-reset-link-wrap hide-if-no-js">
|
||||
<th><?php _e( 'Password Reset' ); ?></th>
|
||||
<td>
|
||||
|
||||
Reference in New Issue
Block a user