Make WordPress Core

Changeset 44985 for branches/5.1


Ignore:
Timestamp:
03/23/2019 03:36:10 AM (5 years ago)
Author:
pento
Message:

Admin: Revert [44984].

That was supposed to go into trunk, not the 5.1 branch.

See #46573.

Location:
branches/5.1
Files:
7 deleted
6 edited

Legend:

Unmodified
Added
Removed
  • branches/5.1/Gruntfile.js

    r44984 r44985  
    264264                    [ WORKING_DIR + 'wp-admin/js/tags-suggest.js' ]: [ './src/js/_enqueues/admin/tags-suggest.js' ],
    265265                    [ WORKING_DIR + 'wp-admin/js/tags.js' ]: [ './src/js/_enqueues/admin/tags.js' ],
    266                     [ WORKING_DIR + 'wp-admin/js/site-health.js' ]: [ './src/js/_enqueues/admin/site-health.js' ],
    267266                    [ WORKING_DIR + 'wp-admin/js/theme-plugin-editor.js' ]: [ './src/js/_enqueues/wp/theme-plugin-editor.js' ],
    268267                    [ WORKING_DIR + 'wp-admin/js/theme.js' ]: [ './src/js/_enqueues/wp/theme.js' ],
  • branches/5.1/src/wp-admin/admin-ajax.php

    r44984 r44985  
    132132    'wp-privacy-export-personal-data',
    133133    'wp-privacy-erase-personal-data',
    134     'health-check-site-status-result',
    135     'health-check-dotorg-communication',
    136     'health-check-is-in-debug-mode',
    137     'health-check-background-updates',
    138     'health-check-loopback-requests',
    139134);
    140135
  • branches/5.1/src/wp-admin/css/wp-admin.css

    r44984 r44985  
    1313@import url(site-icon.css);
    1414@import url(l10n.css);
    15 @import url(site-health.css);
  • branches/5.1/src/wp-admin/includes/ajax-actions.php

    r44984 r44985  
    48364836    wp_send_json_success( $response );
    48374837}
    4838 
    4839 /**
    4840  * Ajax handler for site health checks on server communication.
    4841  *
    4842  * @since 5.2.0
    4843  */
    4844 function wp_ajax_health_check_dotorg_communication() {
    4845     check_ajax_referer( 'health-check-site-status' );
    4846 
    4847     if ( ! current_user_can( 'install_plugins' ) ) {
    4848         wp_send_json_error();
    4849     }
    4850 
    4851     if ( ! class_exists( 'WP_Site_Health' ) ) {
    4852         require_once( ABSPATH . 'wp-admin/includes/class-wp-site-health.php' );
    4853     }
    4854 
    4855     $site_health = new WP_Site_Health();
    4856     wp_send_json_success( $site_health->get_test_dotorg_communication() );
    4857 }
    4858 
    4859 /**
    4860  * Ajax handler for site health checks on debug mode.
    4861  *
    4862  * @since 5.2.0
    4863  */
    4864 function wp_ajax_health_check_is_in_debug_mode() {
    4865     wp_verify_nonce( 'health-check-site-status' );
    4866 
    4867     if ( ! current_user_can( 'install_plugins' ) ) {
    4868         wp_send_json_error();
    4869     }
    4870 
    4871     if ( ! class_exists( 'WP_Site_Health' ) ) {
    4872         require_once( ABSPATH . 'wp-admin/includes/class-wp-site-health.php' );
    4873     }
    4874 
    4875     $site_health = new WP_Site_Health();
    4876     wp_send_json_success( $site_health->get_test_is_in_debug_mode() );
    4877 }
    4878 
    4879 /**
    4880  * Ajax handler for site health checks on background updates.
    4881  *
    4882  * @since 5.2.0
    4883  */
    4884 function wp_ajax_health_check_background_updates() {
    4885     check_ajax_referer( 'health-check-site-status' );
    4886 
    4887     if ( ! current_user_can( 'install_plugins' ) ) {
    4888         wp_send_json_error();
    4889     }
    4890 
    4891     if ( ! class_exists( 'WP_Site_Health' ) ) {
    4892         require_once( ABSPATH . 'wp-admin/includes/class-wp-site-health.php' );
    4893     }
    4894 
    4895     $site_health = new WP_Site_Health();
    4896     wp_send_json_success( $site_health->get_test_background_updates() );
    4897 }
    4898 
    4899 
    4900 /**
    4901  * Ajax handler for site health checks on loopback requests.
    4902  *
    4903  * @since 5.2.0
    4904  */
    4905 function wp_ajax_health_check_loopback_requests() {
    4906     check_ajax_referer( 'health-check-site-status' );
    4907 
    4908     if ( ! current_user_can( 'install_plugins' ) ) {
    4909         wp_send_json_error();
    4910     }
    4911 
    4912     if ( ! class_exists( 'WP_Site_Health' ) ) {
    4913         require_once( ABSPATH . 'wp-admin/includes/class-wp-site-health.php' );
    4914     }
    4915 
    4916     $site_health = new WP_Site_Health();
    4917     wp_send_json_success( $site_health->get_test_loopback_requests() );
    4918 }
    4919 
    4920 /**
    4921  * Ajax handler for site health check to update the result status.
    4922  *
    4923  * @since 5.2.0
    4924  */
    4925 function wp_ajax_health_check_site_status_result() {
    4926     check_ajax_referer( 'health-check-site-status-result' );
    4927 
    4928     if ( ! current_user_can( 'install_plugins' ) ) {
    4929         wp_send_json_error();
    4930     }
    4931 
    4932     set_transient( 'health-check-site-status-result', wp_json_encode( $_POST['counts'] ) );
    4933 
    4934     wp_send_json_success();
    4935 }
  • branches/5.1/src/wp-admin/menu.php

    r44984 r44985  
    257257    $submenu['tools.php'][10] = array( __( 'Import' ), 'import', 'import.php' );
    258258    $submenu['tools.php'][15] = array( __( 'Export' ), 'export', 'export.php' );
    259     $submenu['tools.php'][20] = array( __( 'Site Health' ), 'install_plugins', 'site-health.php' );
    260259if ( is_multisite() && ! is_main_site() ) {
    261260    $submenu['tools.php'][25] = array( __( 'Delete Site' ), 'delete_site', 'ms-delete-site.php' );
  • branches/5.1/src/wp-includes/script-loader.php

    r44984 r44985  
    16381638        );
    16391639
    1640         $scripts->add( 'site-health', "/wp-admin/js/site-health$suffix.js", array( 'jquery', 'wp-util', 'wp-a11y' ), false, 1 );
    1641 
    16421640        $scripts->add( 'updates', "/wp-admin/js/updates$suffix.js", array( 'jquery', 'wp-util', 'wp-a11y' ), false, 1 );
    16431641        did_action( 'init' ) && $scripts->localize(
     
    18851883    $styles->add( 'l10n', "/wp-admin/css/l10n$suffix.css" );
    18861884    $styles->add( 'code-editor', "/wp-admin/css/code-editor$suffix.css", array( 'wp-codemirror' ) );
    1887     $styles->add( 'site-health', "/wp-admin/css/site-health$suffix.css" );
    18881885
    18891886    $styles->add( 'wp-admin', false, array( 'dashicons', 'common', 'forms', 'admin-menu', 'dashboard', 'list-tables', 'edit', 'revisions', 'media', 'themes', 'about', 'nav-menus', 'widgets', 'site-icon', 'l10n' ) );
Note: See TracChangeset for help on using the changeset viewer.