WordPress.org

Make WordPress Core

Ticket #51723: 51723.2.diff

File 51723.2.diff, 773 bytes (added by pbiron, 7 months ago)
  • src/wp-admin/admin.php

    From 1b1d6d6ed98d2d6ad078faf7f83b62a07a13ba8e Mon Sep 17 00:00:00 2001
    From: Paul Biron <paul@sparrowhawkcomputing.com>
    Date: Sat, 14 Nov 2020 14:08:04 -0700
    Subject: [PATCH] Ensure that save_mod_rewrite_rules() is defined before
     calling flush_rewrite_rules() on db_upgraded.
    
    ---
     src/wp-admin/admin.php | 1 +
     1 file changed, 1 insertion(+)
    
    diff --git a/src/wp-admin/admin.php b/src/wp-admin/admin.php
    index 4ead0d51d2..3f78539f9d 100644
    a b require_once dirname( __DIR__ ) . '/wp-load.php'; 
    3636nocache_headers();
    3737
    3838if ( get_option( 'db_upgraded' ) ) {
     39        require_once ABSPATH . 'wp-admin/includes/misc.php';
    3940
    4041        flush_rewrite_rules();
    4142        update_option( 'db_upgraded', false );