Changeset 48666 for trunk/src/wp-admin/includes/class-plugin-upgrader.php
- Timestamp:
- 07/28/2020 04:05:39 PM (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-admin/includes/class-plugin-upgrader.php
r48446 r48666 442 442 } 443 443 444 $requires_php = isset( $info['RequiresPHP'] ) ? $info['RequiresPHP'] : null; 445 $requires_wp = isset( $info['RequiresWP'] ) ? $info['RequiresWP'] : null; 446 447 if ( ! is_php_version_compatible( $requires_php ) ) { 448 $error = sprintf( 449 /* translators: 1: Current PHP version, 2: Version required by the uploaded plugin. */ 450 __( 'The PHP version on your server is %1$s, however the uploaded plugin requires %2$s.' ), 451 phpversion(), 452 $requires_php 453 ); 454 455 return new WP_Error( 'incompatible_php_required_version', $this->strings['incompatible_archive'], $error ); 456 } 457 458 if ( ! is_wp_version_compatible( $requires_wp ) ) { 459 $error = sprintf( 460 /* translators: 1: Current WordPress version, 2: Version required by the uploaded plugin. */ 461 __( 'Your WordPress version is %1$s, however the uploaded plugin requires %2$s.' ), 462 $GLOBALS['wp_version'], 463 $requires_wp 464 ); 465 466 return new WP_Error( 'incompatible_wp_required_version', $this->strings['incompatible_archive'], $error ); 467 } 468 444 469 return $source; 445 470 }
Note: See TracChangeset
for help on using the changeset viewer.