From 88a72182ca1129f76c1abbf84725d0d01ddad93a Mon Sep 17 00:00:00 2001 From: Dion Hulse Date: Tue, 29 Nov 2016 05:37:41 +0000 Subject: [PATCH] WP_Hook: Re-initialize any actions added directly to `$wp_filter` by `advanced-cache.php`. Props dd32, ocean90. Fixes #38929. Built from https://develop.svn.wordpress.org/trunk@39369 git-svn-id: http://core.svn.wordpress.org/trunk@39309 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/version.php | 2 +- wp-settings.php | 7 ++++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/wp-includes/version.php b/wp-includes/version.php index 9d951fff81..da4d607381 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -4,7 +4,7 @@ * * @global string $wp_version */ -$wp_version = '4.8-alpha-39367'; +$wp_version = '4.8-alpha-39369'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema. diff --git a/wp-settings.php b/wp-settings.php index 9fe4080f3f..8dd0f40317 100644 --- a/wp-settings.php +++ b/wp-settings.php @@ -80,8 +80,13 @@ wp_debug_mode(); * Default true. */ if ( WP_CACHE && apply_filters( 'enable_loading_advanced_cache_dropin', true ) ) { -// For an advanced caching plugin to use. Uses a static drop-in because you would only want one. + // For an advanced caching plugin to use. Uses a static drop-in because you would only want one. WP_DEBUG ? include( WP_CONTENT_DIR . '/advanced-cache.php' ) : @include( WP_CONTENT_DIR . '/advanced-cache.php' ); + + // Re-initialize any hooks added manually by advanced-cache.php + if ( $wp_filter ) { + $wp_filter = WP_Hook::build_preinitialized_hooks( $wp_filter ); + } } // Define WP_LANG_DIR if not set.