Make WordPress Core


Ignore:
Timestamp:
05/19/2023 12:44:54 PM (17 months ago)
Author:
spacedmonkey
Message:

Networks and Sites: Load WP_Metadata_Lazyloader class file if class in meta.php.

In [55818] did a check to see if WP_Metadata_Lazyloader class existed and the loaded in the class file if it did not. However, require in wp-settings.php was not removed and resulted in the class being loaded twice. To be safe, only include the class file in meta.php and remove from wp-settings.php file.

Props spacedmonkey, ryelle.
See #58185.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/meta.php

    r55818 r55826  
    1010 * @subpackage Meta
    1111 */
     12
     13require ABSPATH . WPINC . '/class-wp-metadata-lazyloader.php';
    1214
    1315/**
     
    12151217
    12161218    if ( null === $wp_metadata_lazyloader ) {
    1217         if ( ! class_exists( 'WP_Metadata_Lazyloader' ) ) {
    1218             require_once ABSPATH . WPINC . '/class-wp-metadata-lazyloader.php';
    1219         }
    12201219        $wp_metadata_lazyloader = new WP_Metadata_Lazyloader();
    12211220    }
Note: See TracChangeset for help on using the changeset viewer.