From 299c94dd527d2536ea9bb2c641611169428972cd Mon Sep 17 00:00:00 2001
From: Marco Martins <marcomartins@fimdalinha.com>
Date: Fri, 13 Apr 2018 17:10:47 +0300
Subject: [PATCH] Fix CS violations for admin-header.php
---
src/wp-admin/admin-header.php | 13 +++++++------
1 file changed, 7 insertions(+), 6 deletions(-)
diff --git a/src/wp-admin/admin-header.php b/src/wp-admin/admin-header.php
index 5322e2bb65..9130c766f6 100644
|
a
|
b
|
|
| 6 | 6 | * @subpackage Administration |
| 7 | 7 | */ |
| 8 | 8 | |
| 9 | | @header( 'Content-Type: ' . get_option( 'html_type' ) . '; charset=' . get_option( 'blog_charset' ) ); |
| | 9 | @header( 'Content-Type: ' . get_option( 'html_type' ) . '; charset=' . get_option( 'blog_charset' ) ); // phpcs:ignore Generic.PHP.NoSilencedErrors.Discouraged |
| 10 | 10 | if ( ! defined( 'WP_ADMIN' ) ) { |
| 11 | 11 | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 12 | 12 | } |
| … |
… |
if ( empty( $current_screen ) ) { |
| 32 | 32 | } |
| 33 | 33 | |
| 34 | 34 | get_admin_page_title(); |
| 35 | | $title = esc_html( strip_tags( $title ) ); |
| | 35 | $title = esc_html( strip_tags( $title ) ); // phpcs:ignore WordPress.Variables.GlobalVariables.OverrideProhibited |
| 36 | 36 | |
| 37 | 37 | if ( is_network_admin() ) { |
| 38 | 38 | /* translators: Network admin screen title. %s: Network name */ |
| … |
… |
do_action( 'admin_enqueue_scripts', $hook_suffix ); |
| 103 | 103 | * |
| 104 | 104 | * @since 2.6.0 |
| 105 | 105 | */ |
| 106 | | do_action( "admin_print_styles-{$hook_suffix}" ); |
| | 106 | do_action( "admin_print_styles-{$hook_suffix}" ); // phpcs:ignore WordPress.NamingConventions.ValidHookName.UseUnderscores |
| 107 | 107 | |
| 108 | 108 | /** |
| 109 | 109 | * Fires when styles are printed for all admin pages. |
| … |
… |
do_action( 'admin_print_styles' ); |
| 117 | 117 | * |
| 118 | 118 | * @since 2.1.0 |
| 119 | 119 | */ |
| 120 | | do_action( "admin_print_scripts-{$hook_suffix}" ); |
| | 120 | do_action( "admin_print_scripts-{$hook_suffix}" ); // phpcs:ignore WordPress.NamingConventions.ValidHookName.UseUnderscores |
| | 121 | |
| 121 | 122 | |
| 122 | 123 | /** |
| 123 | 124 | * Fires when scripts are printed for all admin pages. |
| … |
… |
do_action( 'admin_print_scripts' ); |
| 134 | 135 | * |
| 135 | 136 | * @since 2.1.0 |
| 136 | 137 | */ |
| 137 | | do_action( "admin_head-{$hook_suffix}" ); |
| | 138 | do_action( "admin_head-{$hook_suffix}" ); // phpcs:ignore WordPress.NamingConventions.ValidHookName.UseUnderscores |
| 138 | 139 | |
| 139 | 140 | /** |
| 140 | 141 | * Fires in head section for all admin pages. |
| … |
… |
if ( is_network_admin() ) { |
| 274 | 275 | */ |
| 275 | 276 | do_action( 'all_admin_notices' ); |
| 276 | 277 | |
| 277 | | if ( $parent_file == 'options-general.php' ) { |
| | 278 | if ( 'options-general.php' === $parent_file ) { |
| 278 | 279 | require( ABSPATH . 'wp-admin/options-head.php' ); |
| 279 | 280 | } |