WordPress.org

Make WordPress Core


Ignore:
Timestamp:
02/01/2020 12:37:14 AM (22 months ago)
Author:
SergeyBiryukov
Message:

Site Health: Rename WP_Site_Health::initialize() introduced in [47063] to ::get_instance(), for clarity and consistency with other core classes.

Use WP_Site_Health::get_instance() where it's needed, instead of creating multiple instances of the class.

Props afercia, xkon, Clorith, SergeyBiryukov.
See #47606.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/includes/class-wp-site-health.php

    r47122 r47149  
    5757     * @return WP_Site_Health|null
    5858     */
    59     public static function initialize() {
     59    public static function get_instance() {
    6060        if ( null === self::$instance ) {
    6161            self::$instance = new WP_Site_Health();
Note: See TracChangeset for help on using the changeset viewer.