[wp-trac] [WordPress Trac] #64636: WP_Theme_JSON: Remove unnecessary array check for value return

WordPress Trac noreply at wordpress.org
Fri Feb 13 13:22:53 UTC 2026


#64636: WP_Theme_JSON: Remove unnecessary array check for value return
--------------------------+-----------------------------
 Reporter:  Soean         |      Owner:  (none)
     Type:  defect (bug)  |     Status:  new
 Priority:  normal        |  Milestone:  Awaiting Review
Component:  General       |    Version:
 Severity:  normal        |   Keywords:
  Focuses:                |
--------------------------+-----------------------------
 We should remove the unnecessary array check for value return at the end
 of the `get_property_value()` method in `WP_Theme_JSON`.


 {{{#!php
 <?php
         if ( is_array( $value ) ) {
                 return $value;
         }

         return $value;
 }
 }}}


 This is a backport of https://github.com/WordPress/gutenberg/pull/75515

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/64636>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list