[wp-trac] [WordPress Trac] #46900: Site Health: count of inactive themes counts default and active themes separately, even when identical

WordPress Trac noreply at wordpress.org
Wed Apr 17 08:24:37 UTC 2019


#46900: Site Health: count of inactive themes counts default and active themes
separately, even when identical
-------------------------------------------------+-------------------------
 Reporter:  johnpgreen                           |       Owner:  (none)
     Type:  defect (bug)                         |      Status:  new
 Priority:  normal                               |   Milestone:  5.2
Component:  Administration                       |     Version:  trunk
 Severity:  normal                               |  Resolution:
 Keywords:  site-health good-first-bug needs-    |     Focuses:
  testing needs-refresh                          |
-------------------------------------------------+-------------------------
Changes (by Clorith):

 * keywords:  site-health good-first-bug has-patch needs-testing 2nd-opinion
     => site-health good-first-bug needs-testing needs-refresh


Comment:

 This is slightly simpler than removing anything.

 We need that counter to accommodate default themes existing when a non-
 default is active, for the inactive themes that "shouldn't" be kept
 around.

 {{{#!php
 // If there's a default theme installed and not in use, we count that as
 allowed as well.
 if ( $has_default_theme && ! $using_default_theme ) {
         $allowed_theme_count++;
 }
 }}}


 This should negate the unwanted behavior in the correct manner I believe,
 only increasing the counter if we're not actually using the default theme.

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


More information about the wp-trac mailing list