Skip to content

Commit

Permalink
Merge pull request #878 from WordPress/fix-not-empty-header-check
Browse files Browse the repository at this point in the history
Make sure headers are not empty in the requires header check
  • Loading branch information
ernilambar authored Feb 21, 2025
2 parents 3b9d76c + d0613c9 commit 4cdda05
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -834,7 +834,7 @@ private function check_requires_headers( Check_Result $result, string $readme_fi
$readme_value = $parser->{$requires[ $require ]['key']};
$plugin_value = $plugin_data[ $requires[ $require ]['header_field'] ];

if ( $readme_value !== $plugin_value ) {
if ( ! empty( $readme_value ) && ! empty( $plugin_value ) && $readme_value !== $plugin_value ) {
$this->add_result_error_for_file(
$result,
sprintf(
Expand Down

0 comments on commit 4cdda05

Please sign in to comment.