Changeset 47219 for trunk/src/wp-admin/includes/plugin.php
- Timestamp:
- 02/09/2020 04:52:28 PM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-admin/includes/plugin.php
r47198 r47219 1835 1835 } 1836 1836 1837 if ( $pagenow == 'admin.php'&& isset( $plugin_page ) ) {1837 if ( 'admin.php' === $pagenow && isset( $plugin_page ) ) { 1838 1838 foreach ( (array) $menu as $parent_menu ) { 1839 1839 if ( $parent_menu[2] == $plugin_page ) { … … 1867 1867 $parent = $_wp_real_parent_file[ $parent ]; 1868 1868 } 1869 if ( ! empty( $typenow ) && ( $submenu_array[2] == "$pagenow?post_type=$typenow") ) {1869 if ( ! empty( $typenow ) && ( "$pagenow?post_type=$typenow" === $submenu_array[2] ) ) { 1870 1870 $parent_file = $parent; 1871 1871 return $parent; … … 1936 1936 ( $parent == $plugin_page ) || 1937 1937 ( $plugin_page == $hook ) || 1938 ( $pagenow == 'admin.php'&& $parent1 != $submenu_array[2] ) ||1938 ( 'admin.php' === $pagenow && $parent1 != $submenu_array[2] ) || 1939 1939 ( ! empty( $typenow ) && $parent == $pagenow . '?post_type=' . $typenow ) 1940 1940 ) … … 1961 1961 if ( isset( $plugin_page ) && 1962 1962 ( $plugin_page == $menu_array[2] ) && 1963 ( $pagenow == 'admin.php') &&1963 ( 'admin.php' === $pagenow ) && 1964 1964 ( $parent1 == $menu_array[2] ) ) { 1965 1965 $title = $menu_array[3]; … … 2157 2157 */ 2158 2158 function add_option_whitelist( $new_options, $options = '' ) { 2159 if ( $options == '') {2159 if ( '' == $options ) { 2160 2160 global $whitelist_options; 2161 2161 } else { … … 2170 2170 } else { 2171 2171 $pos = array_search( $key, $whitelist_options[ $page ] ); 2172 if ( $pos === false) {2172 if ( false === $pos ) { 2173 2173 $whitelist_options[ $page ][] = $key; 2174 2174 } … … 2192 2192 */ 2193 2193 function remove_option_whitelist( $del_options, $options = '' ) { 2194 if ( $options == '') {2194 if ( '' == $options ) { 2195 2195 global $whitelist_options; 2196 2196 } else { … … 2202 2202 if ( isset( $whitelist_options[ $page ] ) && is_array( $whitelist_options[ $page ] ) ) { 2203 2203 $pos = array_search( $key, $whitelist_options[ $page ] ); 2204 if ( $pos !== false) {2204 if ( false !== $pos ) { 2205 2205 unset( $whitelist_options[ $page ][ $pos ] ); 2206 2206 }
Note: See TracChangeset
for help on using the changeset viewer.