Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

added font directory path and size to site health #6260

Closed
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions src/wp-admin/includes/class-wp-debug-data.php
Original file line number Diff line number Diff line change
Expand Up @@ -482,6 +482,15 @@ public static function debug_data() {
'value' => $loading,
'debug' => 'loading...',
),
'fonts_path' => array(
'label' => __( 'Fonts directory location' ),
'value' => wp_get_font_dir()['path'],
audrasjb marked this conversation as resolved.
Show resolved Hide resolved
),
'fonts_size' => array(
'label' => __( 'Fonts directory size' ),
'value' => $loading,
'debug' => 'loading...',
),
'database_size' => array(
'label' => __( 'Database size' ),
'value' => $loading,
Expand Down Expand Up @@ -1636,6 +1645,7 @@ public static function get_sizes() {
'themes_size' => get_theme_root(),
'plugins_size' => WP_PLUGIN_DIR,
'uploads_size' => $upload_dir['basedir'],
'fonts_size' => wp_get_font_dir()['path'],
audrasjb marked this conversation as resolved.
Show resolved Hide resolved
);

$exclude = $paths;
Expand Down
2 changes: 1 addition & 1 deletion src/wp-admin/site-health-info.php
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@

<?php

$sizes_fields = array( 'uploads_size', 'themes_size', 'plugins_size', 'wordpress_size', 'database_size', 'total_size' );
$sizes_fields = array( 'uploads_size', 'themes_size', 'plugins_size', 'fonts_size', 'wordpress_size', 'database_size', 'total_size' );

foreach ( $info as $section => $details ) {
if ( ! isset( $details['fields'] ) || empty( $details['fields'] ) ) {
Expand Down
Loading