Skip to content

Commit 18b5794

Browse files
committed
Fix addons not showing as tested up to minor WordPress versions
1 parent 20a3c7d commit 18b5794

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

includes/wpum-updater/EDD_SL_Plugin_Updater.php

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -348,6 +348,16 @@ public function plugins_api_filter( $_data, $_action = '', $_args = null ) {
348348
$_data->plugin = $this->name;
349349
}
350350

351+
// Ensure minor versions of WordPress are still shown as compatible with the addon.
352+
// Do not remove when updating this class from upstream.
353+
if ( empty( $_data->tested ) ) {
354+
$_data->tested = get_bloginfo( 'version' );
355+
} else {
356+
if ( version_compare( $_data->tested, get_bloginfo( 'version' ), '<' ) && 0 == stripos( get_bloginfo( 'version' ), $_data->tested . '.' ) ) {
357+
$_data->tested = get_bloginfo( 'version' );
358+
}
359+
}
360+
351361
return $_data;
352362
}
353363

0 commit comments

Comments
 (0)