diff --git a/wp-admin/admin-db.php b/wp-admin/admin-db.php index 5e16fe7770..848e1eb630 100644 --- a/wp-admin/admin-db.php +++ b/wp-admin/admin-db.php @@ -266,14 +266,14 @@ function wp_delete_user($id, $reassign = 'novalue') { } // FINALLY, delete user + do_action('delete_user', $id); + $wpdb->query("DELETE FROM $wpdb->users WHERE ID = $id"); $wpdb->query("DELETE FROM $wpdb->usermeta WHERE user_id = '$id'"); wp_cache_delete($id, 'users'); wp_cache_delete($user->user_login, 'userlogins'); - do_action('delete_user', $id); - return true; }