[wp-trac] [WordPress Trac] #46726: Site health: the site data is gathered twice on non-English locales
WordPress Trac
noreply at wordpress.org
Fri Mar 29 20:16:46 UTC 2019
#46726: Site health: the site data is gathered twice on non-English locales
----------------------------+--------------------
Reporter: azaozz | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: 5.2
Component: Administration | Version: trunk
Severity: normal | Keywords:
Focuses: |
----------------------------+--------------------
Follow-up from https://core.trac.wordpress.org/ticket/46645#comment:27.
{{{
WP_Debug_Data::check_for_updates();
$info = WP_Debug_Data::debug_data();
$english_info = '';
if ( 0 !== strpos( get_locale(), 'en' ) ) {
$english_info = WP_Debug_Data::debug_data( 'en_US' );
}
}}}
`WP_Debug_Data::debug_data()` is quite slow, shouldn't be run twice. As
far as I see the only difference in the data are the translated strings.
Ideally we can separate the actual data from the "presentation" (the array
used to output the HTML later on). Then can reuse the data as needed.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/46726>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list