Make WordPress Core

Opened 5 years ago

Closed 5 years ago

Last modified 5 years ago

#55170 closed enhancement (fixed)

Remove commented code from remove_user_from_blog()

Reported by: Faison Owned by: audrasjb
Priority: normal Milestone: 6.0
Component: Networks and Sites Version:
Severity: normal Keywords: has-patch
Cc: Focuses: docs, multisite, coding-standards

Description

The function remove_user_from_blog() contains a commented out call to the function wp_revoke_user() (See source:/trunk/src/wp-includes/ms-functions.php#L283​.

This commented line exists as far back as 2011 (see changeset:17379), and the only update to that line since then has been to update its code style (see changeset:47122).

Attachments (1)

55170.diff​ (418 bytes ) - added by Faison 5 years ago.

Download all attachments as: .zip

Change History (6)

#1 @audrasjb
5 years ago

  • Component General → Networks and Sites
  • Focuses docs multisite added
  • Keywords has-patch added
  • Milestone Awaiting Review → 6.0
  • Owner set to audrasjb
  • Status new → reviewing
  • Version trunk

#2 @azouamauriac
5 years ago

  • Focuses coding-standards added

Hello there thanks for your report. It makes sens I think. Focuses as coding-standards because I think it is good practice to not let commented code in production.

#3 @audrasjb
5 years ago

  • Resolution → fixed
  • Status reviewing → closed

In 52737:

Networks and Sites: Remove unnecessary commented code from remove_user_from_blog().

This change removes a call to wp_revoke_user() from remove_user_from_blog(): this line has been commented out since forever.

Props Faison.
Fixes #55170.

#4 @SergeyBiryukov
5 years ago

Some history here:

#5 @audrasjb
5 years ago

Wow, thanks for retrieving the full history. I stopped when I reached @since mu-3.0.0 😍

This research deserves a late props (and missing props actually added manually) 😃

Note: See TracTickets for help on using tickets.