Make WordPress Core

Opened 8 months ago

Closed 8 months ago

#59977 closed defect (bug) (fixed)

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

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

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 8 months ago.

Download all attachments as: .zip

Change History (3)

@upadalavipul
8 months ago

#1 @mukesh27
8 months ago

  • Component changed from General to Site Health
  • Keywords has-patch added
  • Milestone changed from Awaiting Review to 6.5
  • Version set to 5.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
8 months ago

  • Owner set to SergeyBiryukov
  • Resolution set to fixed
  • Status changed from new to closed

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.