Themes: Correct the logic for displaying a message in theme grid if a theme update requires a higher version of PHP or WordPress.

This applies to the Themes screen fallback used when JS is turned off.

Follow-up to [48652].

See #48491.

git-svn-id: https://develop.svn.wordpress.org/trunk@48653 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Sergey Biryukov 2020-07-28 00:41:56 +00:00
parent 7ea44b5add
commit d29535c25e

View File

@ -400,7 +400,7 @@ foreach ( $themes as $theme ) :
<?php else : ?>
<div class="notice inline notice-error notice-alt"><p>
<?php
if ( $theme['updateResponse']['compatibleWP'] && $theme['updateResponse']['compatiblePHP'] ) {
if ( ! $theme['updateResponse']['compatibleWP'] && ! $theme['updateResponse']['compatiblePHP'] ) {
_e( 'There is a new version available, but it doesn&#8217;t work with your versions of WordPress and PHP.' );
if ( current_user_can( 'update_core' ) && current_user_can( 'update_php' ) ) {
printf(