[wp-trac] [WordPress Trac] #61565: Rename wp_maintenance to maybe_show_wp_maintenance

WordPress Trac noreply at wordpress.org
Fri Aug 16 18:08:49 UTC 2024


#61565: Rename wp_maintenance to maybe_show_wp_maintenance
--------------------------------------------+------------------------------
 Reporter:  ramon fincken                   |       Owner:  (none)
     Type:  enhancement                     |      Status:  new
 Priority:  normal                          |   Milestone:  Awaiting Review
Component:  Bootstrap/Load                  |     Version:  6.6
 Severity:  normal                          |  Resolution:
 Keywords:  has-unit-tests has-patch close  |     Focuses:
--------------------------------------------+------------------------------

Comment (by ramon fincken):

 In that case, the alternative would be ( keeping all function names the
 same ) :

 OPEN
 wp-settings.php

 FIND
 {{{
 wp_maintenance();

 }}}


 REPLACE WITH
 {{{
 if( wp_is_maintenance_mode() ) {
         wp_maintenance();
 }

 }}}

 OPEN
 wp-includes/load.php

 FIND
 {{{
 function wp_maintenance() {
         // Return if maintenance mode is disabled.
         if ( ! wp_is_maintenance_mode() ) {
                 return;
         }

 }}}

 REPLACE WITH
 {{{
 function wp_maintenance() {

 }}}

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/61565#comment:6>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list