#1493 closed defect (bug) (fixed)
User's links aren't deleted if they've got no posts when deleting a user [PATCH]
Reported by: | davidhouse | Owned by: | skippy |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | 1.6 |
Component: | Administration | Keywords: | user links bg|has-patch bg|commit |
Focuses: | Cc: |
Description
In the function wp_delete_user() in wp-admin/admin-functions.php, an if () statement surrounds a bunch of queries. This is done to ensure those queries aren't executed if the user doesn't have any posts. This makes sense, but the query to delete a user's links is inside that check, too. A user may have links but no posts, and so this could lead to orphaned links.
Patch attached.
Attachments (1)
Change History (5)
Note: See
TracTickets for help on using
tickets.
This looks good to me. I'm passing it along for commit.