Make WordPress Core

Ticket #47087: 47087.diff

File 47087.diff, 455 bytes (added by bsetiawan88, 6 years ago)
  • src/wp-includes/rewrite.php

    diff --git a/src/wp-includes/rewrite.php b/src/wp-includes/rewrite.php
    index a03754f272..8041f221f3 100644
    a b function add_feed( $feedname, $function ) { 
    273273 */
    274274function flush_rewrite_rules( $hard = true ) {
    275275        global $wp_rewrite;
    276         $wp_rewrite->flush_rules( $hard );
     276        if ( is_callable ( $wp_rewrite->flush_rules ) ) {
     277                $wp_rewrite->flush_rules( $hard );
     278        }
    277279}
    278280
    279281/**