[wp-trac] [WordPress Trac] #48005: PHPDoc correction for WP_Theme::get

WordPress Trac noreply at wordpress.org
Mon Sep 9 11:37:53 UTC 2019


#48005: PHPDoc correction for WP_Theme::get
-------------------------+-----------------------------
 Reporter:  david.binda  |      Owner:  (none)
     Type:  enhancement  |     Status:  new
 Priority:  normal       |  Milestone:  Awaiting Review
Component:  General      |    Version:  3.4
 Severity:  normal       |   Keywords:
  Focuses:               |
-------------------------+-----------------------------
 The PHPDoc for the `WP_Theme::get` function says it returns `string|false`
 (added in r32547 ), but it actually may return an array for "Tags" header
 (via `WP_Theme::sanitize_header`).

 mixed, as used in `WP_Theme::sanitize_header` may better document the
 actual state.

 Related code:
 * https://core.trac.wordpress.org/browser/trunk/src/wp-includes/class-wp-
 theme.php?rev=45932#L849
 * https://core.trac.wordpress.org/browser/trunk/src/wp-includes/class-wp-
 theme.php?rev=45932#L757
 * https://core.trac.wordpress.org/browser/trunk/src/wp-includes/class-wp-
 theme.php?rev=45932#L761

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


More information about the wp-trac mailing list