Skip to content

Commit a73eca1

Browse files
Site Health: Correct markup in ::get_test_php_extensions() and ::get_test_background_updates() description.
These tests output an unordered list, which doesn't need to be wrapped in a paragraph tag. Additionally, pass an empty string as an `actions` parameter in `::get_test_php_default_timezone()`, for consistency with other tests. Props afercia. See #48948. git-svn-id: https://develop.svn.wordpress.org/trunk@47528 602fd350-edb4-49c9-b593-d223f7449a82
1 parent 96a35da commit a73eca1

1 file changed

Lines changed: 3 additions & 8 deletions

File tree

src/wp-admin/includes/class-wp-site-health.php

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1036,10 +1036,7 @@ public function get_test_php_extensions() {
10361036
$result['label'] = __( 'One or more required modules are missing' );
10371037
}
10381038

1039-
$result['description'] .= sprintf(
1040-
'<p>%s</p>',
1041-
$output
1042-
);
1039+
$result['description'] .= $output;
10431040
}
10441041

10451042
return $result;
@@ -1064,6 +1061,7 @@ public function get_test_php_default_timezone() {
10641061
'<p>%s</p>',
10651062
__( 'PHP default timezone was configured by WordPress on loading. This is necessary for correct calculations of dates and times.' )
10661063
),
1064+
'actions' => '',
10671065
'test' => 'php_default_timezone',
10681066
);
10691067

@@ -1678,10 +1676,7 @@ public function get_test_background_updates() {
16781676
$output .= '</ul>';
16791677

16801678
if ( 'good' !== $result['status'] ) {
1681-
$result['description'] .= sprintf(
1682-
'<p>%s</p>',
1683-
$output
1684-
);
1679+
$result['description'] .= $output;
16851680
}
16861681

16871682
return $result;

0 commit comments

Comments
 (0)