Make WordPress Core

Opened 3 months ago

Last modified 2 months ago

#61149 new enhancement

class WP_User(), mark prop $deleted as deprecated

Reported by: ignatiusjeroe's profile ignatiusjeroe Owned by:
Milestone: Awaiting Review Priority: normal
Severity: trivial Version:
Component: Users Keywords: has-patch
Focuses: Cc:

Description

I've search the source code for the utility of column deleted in database table Users. There is only one mention of it in function wp_update_user_counts(), but that seems like irrelevant since 'spam' seems like its replacement. If that is the case the WP_User class should change the comment

current:

* @property string $deleted

replacement:

* @property string $deleted Deprecated. Use {@see $spam} instead.

mark

Change History (1)

This ticket was mentioned in PR #6758 on WordPress/wordpress-develop by @snehapatil02.


2 months ago
#1

  • Keywords has-patch added

### Ticket: https://core.trac.wordpress.org/ticket/61149

## Description
Ensure consistent handling of 'checked' property in wp_update_plugins() function.

  • This PR addresses ticket #61149 by marking the $deleted property in the WP_User class as deprecated.
  • After reviewing the WordPress core code, it was found that the $deleted column is only mentioned once in the function wp_update_user_counts().
  • This reference appears to be irrelevant since the $spam property has replaced its functionality. To reflect this change, the documentation for the WP_User class is updated accordingly.

## Changes Made

  • Updated the docblock for the $deleted property in the WP_User class to mark it as deprecated.
  • Added a reference to use the $spam property instead.
Note: See TracTickets for help on using tickets.