Make WordPress Core

Ticket #29154: 29154.2.diff

File 29154.2.diff, 637 bytes (added by voldemortensen, 10 years ago)
  • src/wp-includes/plugin.php

     
    654654function plugin_basename( $file ) {
    655655        global $wp_plugin_paths;
    656656
     657        $file = wp_normalize_path( $file );
     658
    657659        foreach ( $wp_plugin_paths as $dir => $realdir ) {
    658660                if ( strpos( $file, $realdir ) === 0 ) {
    659661                        $file = $dir . substr( $file, strlen( $realdir ) );
    660662                }
    661663        }
    662664
    663         $file = wp_normalize_path( $file );
    664665        $plugin_dir = wp_normalize_path( WP_PLUGIN_DIR );
    665666        $mu_plugin_dir = wp_normalize_path( WPMU_PLUGIN_DIR );
    666667