[wp-trac] [WordPress Trac] #20103: Rewrite get_themes() and other enemies of sanity
WordPress Trac
wp-trac at lists.automattic.com
Thu Mar 15 15:39:25 UTC 2012
#20103: Rewrite get_themes() and other enemies of sanity
--------------------------+------------------
Reporter: nacin | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: 3.4
Component: Themes | Version: 1.5
Severity: normal | Resolution:
Keywords: has-patch |
--------------------------+------------------
Comment (by nacin):
In [20193]:
{{{
#!CommitTicketReference repository="" revision="20193"
Updates to WP_Theme, wp_get_themes(), and related deprecated functions,
after [UT570] [UT578] [UT579]. see #20103.
* ['Template Files'] and ['Stylesheet Files'] need to return files from
the parent theme as well.
* Don't strip links from the Author header. Some themes rely on the
previous behavior, such as to link multiple authors (Sandbox, for
example.) Don't restore links to the Name, that's just a bad idea.
* Ensure we are always passing around arrays in get_files/scandir.
* Better inline doc for wp_get_themes() arguments.
* Introduce a 'force' flag for search_theme_directories() to re-scan,
rather than return the cache. We will use this to re-build the theme_roots
transient in get_theme_roots(), but it is more helpful for unit tests.
Since search_theme_directories() is cached, don't cache again in
wp_get_themes(). (Again benefits testing.)
* Handle duplicate theme names in the old get_themes() when two themes
match (and neither are a default theme, which is already handled).
wp_get_themes() will consider both names to be the same; this is just for
back compat since get_themes() is keyed by name.
* Include an old array key in wp_broken_themes().
}}}
--
Ticket URL: <http://core.trac.wordpress.org/ticket/20103#comment:29>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list