Changeset 51629
- Timestamp:
- 08/17/2021 09:55:22 PM (3 years ago)
- Location:
- trunk/src/wp-admin
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-admin/plugin-editor.php
r51475 r51629 313 313 $excluded_referer_basenames = array( 'plugin-editor.php', 'wp-login.php' ); 314 314 315 if ( $referer && ! in_array( basename( parse_url( $referer, PHP_URL_PATH ) ), $excluded_referer_basenames, true ) ) { 316 $return_url = $referer; 317 } else { 318 $return_url = admin_url( '/' ); 315 $return_url = admin_url( '/' ); 316 if ( $referer ) { 317 $referer_path = parse_url( $referer, PHP_URL_PATH ); 318 if ( is_string( $referer_path ) && ! in_array( basename( $referer_path ), $excluded_referer_basenames, true ) ) { 319 $return_url = $referer; 320 } 319 321 } 320 322 ?> -
trunk/src/wp-admin/theme-editor.php
r51475 r51629 344 344 $excluded_referer_basenames = array( 'theme-editor.php', 'wp-login.php' ); 345 345 346 if ( $referer && ! in_array( basename( parse_url( $referer, PHP_URL_PATH ) ), $excluded_referer_basenames, true ) ) { 347 $return_url = $referer; 348 } else { 349 $return_url = admin_url( '/' ); 346 $return_url = admin_url( '/' ); 347 if ( $referer ) { 348 $referer_path = parse_url( $referer, PHP_URL_PATH ); 349 if ( is_string( $referer_path ) && ! in_array( basename( $referer_path ), $excluded_referer_basenames, true ) ) { 350 $return_url = $referer; 351 } 350 352 } 351 353 ?>
Note: See TracChangeset
for help on using the changeset viewer.