Make WordPress Core

Opened 3 years ago

Closed 3 years ago

#59977 closed defect (bug) (fixed)

Remove the Unused global variables in the class-wp-site-health.php file.

Reported by: upadalavipul Owned by: SergeyBiryukov
Priority: normal Milestone: 6.5
Component: Site Health Version: 5.2
Severity: normal Keywords: has-patch
Cc: Focuses: coding-standards

Description

I have reviewed the class-wp-site-health.php file code and found the get_test_utf8mb4_support function unused global $wpdb variable. So we need to remove the here $wpdb global variable.

File Path: wp-admin/includes/class-wp-site-health.php

Attachments (1)

59977.patch (545 bytes ) - added by upadalavipul 3 years ago.

Download all attachments as: .zip

Change History (3)

@upadalavipul
3 years ago

#1 @mukesh27
3 years ago

  • Component GeneralSite Health
  • Keywords has-patch added
  • Milestone Awaiting Review6.5
  • Version5.2

Thanks for the ticket and patch!

Nice catch, The global was introduce in [44984] / #46573 and in [56475] / #59118 we removed the use of that global so we should remove that global.

#2 @SergeyBiryukov
3 years ago

  • Owner set to SergeyBiryukov
  • Resolutionfixed
  • Status newclosed

In 57141:

Site Health: Remove unused $wpdb global in utf8mb4 support test.

Follow-up to [44984], [56475].

Props upadalavipul, mukesh27.
Fixes #59977.

Note: See TracTickets for help on using tickets.