norcross / debug-quick-look

Adds a link to view or purge the debug.log file in WordPress
MIT License
28 stars 10 forks source link

Rewrite branch not recognized as plugin #8

Closed afragen closed 6 years ago

afragen commented 6 years ago

It seems that WP want to see the plugin headers with a following : and no space. Otherwise the header isn't recognized.

wp-includes/functions.php line 5182 in trunk

    foreach ( $all_headers as $field => $regex ) {
        if ( preg_match( '/^[ \t\/*#@]*' . preg_quote( $regex, '/' ) . ':(.*)$/mi', $file_data, $match ) && $match[1] ) {
            $all_headers[ $field ] = _cleanup_header_comment( $match[1] );
        } else {
            $all_headers[ $field ] = '';
        }
    }
norcross commented 6 years ago

@afragen take a look at this commit, it should resolve the issue.