[wp-trac] [WordPress Trac] #48153: Allow the admin email verification capability to be filtered
WordPress Trac
noreply at wordpress.org
Thu Sep 26 22:20:06 UTC 2019
#48153: Allow the admin email verification capability to be filtered
------------------------------+-----------------------------
Reporter: desrosj | Owner: desrosj
Type: defect (bug) | Status: reopened
Priority: normal | Milestone: 5.3
Component: Site Health | Version: trunk
Severity: normal | Resolution:
Keywords: has-patch commit | Focuses: administration
------------------------------+-----------------------------
Changes (by azaozz):
* status: closed => reopened
* resolution: fixed =>
Comment:
Looking at `admin_email_check_cap` filter, there is a somewhat high
possibility for plugins to be "doing-it-wrong" there? All users that are
redirected will have to have the `manage_options` capability or they won't
be able to update the email address.
The intended functionality can be done by using the
`admin_email_check_interval` filter and looking at the current user. If
additional capabilities are required, the standard `current_user_can()`
can be used as well. Then the redirect can be disabled on per-user basis
by retiring a "falsey" value, see
https://core.trac.wordpress.org/browser/trunk/src/wp-
login.php?rev=46325#L1246.
Perhaps would be better to update the docs and describe the user case in
more details?
--
Ticket URL: <https://core.trac.wordpress.org/ticket/48153#comment:9>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list