[wp-trac] [WordPress Trac] #36860: Introduce filter for users_have_content within delete action of users.php
WordPress Trac
noreply at wordpress.org
Tue May 17 04:52:36 UTC 2016
#36860: Introduce filter for users_have_content within delete action of users.php
-----------------------------+-----------------------------
Reporter: garrett-eclipse | Owner:
Type: enhancement | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Users | Version: trunk
Severity: normal | Keywords:
Focuses: administration |
-----------------------------+-----------------------------
Hello,
I'd like to request an enhancement on the delete action for users.
Idea - https://wordpress.org/ideas/topic/introduce-filter-for-
users_have_content-within-delete-action-of-usersphp?replies=1#post-30346
The addition of a filter for line 220 of the users.php
https://core.trac.wordpress.org/browser/trunk/src/wp-admin/users.php#L220
Proposed filter;
{{{#!php
<?php
/**
* Filter the users_have_content, also known as the users have content
flag, before use.
*
* @since ###
*
* @param boolean $users_have_content The flag for users have content.
*/
$users_have_content = apply_filters( 'users_have_content',
$users_have_content, $userids ) );
}}}
Allows for plugins to introduce reassign capabilities when their user
relational data isn't handled through the posts_author or link_owner
database checks.
Example: Co Authors Plus saves additional author information in taxonomy
terms. If a co-author is removed currently no reassignment can be made.
With the filter the userids can be checked for coauthor relationships so
as to enable the reassign user ability.
Thank you
--
Ticket URL: <https://core.trac.wordpress.org/ticket/36860>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list