Changeset 45239
- Timestamp:
- 04/18/2019 12:33:03 AM (7 years ago)
- Location:
- trunk/src
- Files:
-
- 3 edited
-
js/_enqueues/admin/site-health.js (modified) (3 diffs)
-
wp-admin/includes/ajax-actions.php (modified) (1 diff)
-
wp-admin/includes/class-wp-debug-data.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/js/_enqueues/admin/site-health.js
r45220 r45239 16 16 var clipboard = new ClipboardJS( '.site-health-copy-buttons .copy-button' ); 17 17 var isDebugTab = $( '.health-check-body.health-check-debug-tab' ).length; 18 var pathsSizesSection = $( '#health-check-accordion-block-wp-paths-sizes' ); 18 19 19 20 // Debug information copy section. … … 296 297 copyButton.attr( 'data-clipboard-text', clipdoardText ); 297 298 298 $( '#health-check-accordion-block-wp-paths-sizes' ).find( 'td[class]' ).each( function( i, element ) {299 pathsSizesSection.find( 'td[class]' ).each( function( i, element ) { 299 300 var td = $( element ); 300 301 var name = td.attr( 'class' ); … … 307 308 308 309 if ( isDebugTab ) { 309 getDirectorySizes(); 310 if ( pathsSizesSection.length ) { 311 getDirectorySizes(); 312 } else { 313 RecalculateProgression(); 314 } 310 315 } 311 316 } ); -
trunk/src/wp-admin/includes/ajax-actions.php
r45220 r45239 4968 4968 check_ajax_referer( 'health-check-site-status-result' ); 4969 4969 4970 if ( ! current_user_can( 'install_plugins' ) ) {4970 if ( ! current_user_can( 'install_plugins' ) || is_multisite() ) { 4971 4971 wp_send_json_error(); 4972 4972 } -
trunk/src/wp-admin/includes/class-wp-debug-data.php
r45237 r45239 110 110 ); 111 111 112 $info['wp-paths-sizes'] = array( 113 'label' => __( 'Directories and Sizes' ), 114 'fields' => array(), 115 ); 112 if ( ! $is_multisite ) { 113 $info['wp-paths-sizes'] = array( 114 'label' => __( 'Directories and Sizes' ), 115 'fields' => array(), 116 ); 117 } 116 118 117 119 $info['wp-dropins'] = array( … … 390 392 } 391 393 392 $loading = __( 'Loading…' ); 393 394 $info['wp-paths-sizes']['fields'] = array( 395 'wordpress_path' => array( 396 'label' => __( 'WordPress directory location' ), 397 'value' => untrailingslashit( ABSPATH ), 398 ), 399 'wordpress_size' => array( 400 'label' => __( 'WordPress directory size' ), 401 'value' => $loading, 402 'debug' => 'loading...', 403 ), 404 'uploads_path' => array( 405 'label' => __( 'Uploads directory location' ), 406 'value' => $upload_dir['basedir'], 407 ), 408 'uploads_size' => array( 409 'label' => __( 'Uploads directory size' ), 410 'value' => $loading, 411 'debug' => 'loading...', 412 ), 413 'themes_path' => array( 414 'label' => __( 'Themes directory location' ), 415 'value' => get_theme_root(), 416 ), 417 'themes_size' => array( 418 'label' => __( 'Themes directory size' ), 419 'value' => $loading, 420 'debug' => 'loading...', 421 ), 422 'plugins_path' => array( 423 'label' => __( 'Plugins directory location' ), 424 'value' => WP_PLUGIN_DIR, 425 ), 426 'plugins_size' => array( 427 'label' => __( 'Plugins directory size' ), 428 'value' => $loading, 429 'debug' => 'loading...', 430 ), 431 'database_size' => array( 432 'label' => __( 'Database size' ), 433 'value' => $loading, 434 'debug' => 'loading...', 435 ), 436 'total_size' => array( 437 'label' => __( 'Total installation size' ), 438 'value' => $loading, 439 'debug' => 'loading...', 440 ), 441 ); 394 // Remove accordion for Directories and Sizes if in Multisite. 395 if ( ! $is_multisite ) { 396 $loading = __( 'Loading…' ); 397 398 $info['wp-paths-sizes']['fields'] = array( 399 'wordpress_path' => array( 400 'label' => __( 'WordPress directory location' ), 401 'value' => untrailingslashit( ABSPATH ), 402 ), 403 'wordpress_size' => array( 404 'label' => __( 'WordPress directory size' ), 405 'value' => $loading, 406 'debug' => 'loading...', 407 ), 408 'uploads_path' => array( 409 'label' => __( 'Uploads directory location' ), 410 'value' => $upload_dir['basedir'], 411 ), 412 'uploads_size' => array( 413 'label' => __( 'Uploads directory size' ), 414 'value' => $loading, 415 'debug' => 'loading...', 416 ), 417 'themes_path' => array( 418 'label' => __( 'Themes directory location' ), 419 'value' => get_theme_root(), 420 ), 421 'themes_size' => array( 422 'label' => __( 'Themes directory size' ), 423 'value' => $loading, 424 'debug' => 'loading...', 425 ), 426 'plugins_path' => array( 427 'label' => __( 'Plugins directory location' ), 428 'value' => WP_PLUGIN_DIR, 429 ), 430 'plugins_size' => array( 431 'label' => __( 'Plugins directory size' ), 432 'value' => $loading, 433 'debug' => 'loading...', 434 ), 435 'database_size' => array( 436 'label' => __( 'Database size' ), 437 'value' => $loading, 438 'debug' => 'loading...', 439 ), 440 'total_size' => array( 441 'label' => __( 'Total installation size' ), 442 'value' => $loading, 443 'debug' => 'loading...', 444 ), 445 ); 446 } 442 447 443 448 // Get a list of all drop-in replacements.
Note: See TracChangeset
for help on using the changeset viewer.