mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-08-11 20:30:23 +00:00
Reduce references to the $wp_rewrite global because it's no longer used or a wrapper function can be used instead. Fixes #14546.#14546.
git-svn-id: https://develop.svn.wordpress.org/trunk@20023 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -196,17 +196,15 @@ function update_recently_edited( $file ) {
|
||||
*
|
||||
* @since 2.1.0
|
||||
*
|
||||
* @param unknown_type $old_value
|
||||
* @param unknown_type $value
|
||||
* @param string $old_value
|
||||
* @param string $value
|
||||
*/
|
||||
function update_home_siteurl( $old_value, $value ) {
|
||||
global $wp_rewrite;
|
||||
|
||||
if ( defined( "WP_INSTALLING" ) )
|
||||
return;
|
||||
|
||||
// If home changed, write rewrite rules to new location.
|
||||
$wp_rewrite->flush_rules();
|
||||
flush_rewrite_rules();
|
||||
}
|
||||
|
||||
add_action( 'update_option_home', 'update_home_siteurl', 10, 2 );
|
||||
|
||||
Reference in New Issue
Block a user