Update UpdateChecker.php - add check

This commit is contained in:
David Anderson 2024-10-12 18:21:50 +00:00 committed by GitHub
parent cc5c8d9eca
commit a622b0047a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 2 additions and 0 deletions

View File

@ -292,6 +292,8 @@ if ( !class_exists(UpdateChecker::class, false) ):
$reportingItems = json_decode($args['body'][$typePluralised], true);
if ( null === $reportingItems ) return $args;
foreach ( $reportingItems[$typePluralised] as $key => $item ) {
// https://make.wordpress.org/core/2021/06/29/introducing-update-uri-plugin-header-in-wordpress-5-8/
if (dirname($key) === $this->directoryName) {