WordPress.org

Make WordPress Core

Ticket #15193: 15193.2.diff

File 15193.2.diff, 545 bytes (added by scribu, 4 years ago)

slightly more permissive

  • wp-includes/functions.php

     
    42244224 
    42254225 
    42264226        foreach ( $all_headers as $field => $regex ) { 
    4227                 preg_match( '/' . preg_quote( $regex, '/' ) . ':(.*)$/mi', $file_data, ${$field}); 
     4227                preg_match( '/^[\s\/*#]*' . preg_quote( $regex, '/' ) . ':(.*)$/mi', $file_data, ${$field}); 
    42284228                if ( !empty( ${$field} ) ) 
    42294229                        ${$field} = _cleanup_header_comment( ${$field}[1] ); 
    42304230                else