[wp-trac] [WordPress Trac] #37699: Death to Globals Episode #1: A Registry, A Pattern

WordPress Trac noreply at wordpress.org
Thu Aug 25 19:08:40 UTC 2016


#37699: Death to Globals Episode #1: A Registry, A Pattern
----------------------------+------------------
 Reporter:  wonderboymusic  |       Owner:
     Type:  enhancement     |      Status:  new
 Priority:  normal          |   Milestone:  4.7
Component:  General         |     Version:
 Severity:  normal          |  Resolution:
 Keywords:                  |     Focuses:
----------------------------+------------------

Comment (by wonderboymusic):

 In [changeset:"38355"]:
 {{{
 #!CommitTicketReference repository="" revision="38355"
 Site Icon: There is no good reason for `class-wp-site-icon.php` to drop a
 global instance of itself whenever the file is loaded. The lone use of the
 `global` instance of `WP_Site_Icon` is in an AJAX action that provides
 virtually no way to override - the file is loaded immediately before the
 `global` is used.

 Let us remove the `$wp_site_icon` global. I will fall on the sword if this
 comes back to bite us (waiting with bated breath).

 See #37699.
 }}}

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


More information about the wp-trac mailing list