Making WordPress.org

Ticket #4694: 4694-1.diff

File 4694-1.diff, 2.4 KB (added by Ipstenu, 5 years ago)
  • trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-plugins/inc/template-tags.php

     
    209209                        break;
    210210
    211211                case 'disabled':
    212                         $message = current_user_can( 'plugin_approve' )
    213                                 ? __( 'This plugin is disabled (closed, but actively serving updates).', 'wporg-plugins' )
    214                                 : __( 'This plugin has been closed for new installations.', 'wporg-plugins' );
    215 
    216                         $message = sprintf( $error_notice, $message );
    217                         break;
    218 
    219212                case 'closed':
    220213                        $closed_date = get_post_meta( get_the_ID(), 'plugin_closed_date', true );
    221214
    222215                        if ( $closed_date ) {
    223                                 /* translators: %s: plugin closing date */
    224                                 $message = sprintf( __( 'This plugin was closed on %s and is no longer available for download.', 'wporg-plugins' ), mysql2date( get_option( 'date_format' ), $closed_date ) );
    225216
     217                                if ( 'disabled' === $post_status && current_user_can( 'plugin_approve' ) ) {
     218                                        /* translators: %s: plugin closing date */
     219                                        $message = sprintf( __( 'This plugin has been disabled as of %s -- this means it is closed, but actively serving updates.', 'wporg-plugins' ), mysql2date( get_option( 'date_format' ), $closed_date ) );
     220                                } else {
     221                                        /* translators: %s: plugin closing date */
     222                                        $message = sprintf( __( 'This plugin has been closed as of %s and is not available for download.', 'wporg-plugins' ), mysql2date( get_option( 'date_format' ), $closed_date ) );
     223                                }
     224
    226225                                $days_passed = (int) ( ( current_time( 'timestamp' ) - mysql2date( 'U', $closed_date ) ) / DAY_IN_SECONDS );
    227226
    228227                                // Display close reason if more than 60 days have passed.
    229228                                if ( $days_passed > 60 ) {
    230229                                        /* translators: %s: plugin close/disable reason */
    231                                         $message .= ' ' . sprintf( __( 'Reason: %s.', 'wporg-plugins' ), Template::get_close_reason( $post ) );
     230                                        $message     .= ' ' . sprintf( __( 'Reason: %s.', 'wporg-plugins' ), Template::get_close_reason( $post ) );
     231                                } else {
     232                                        $message .= ' ' . __( 'This closure is temporary, pending a full review.', 'wporg-plugins' );
    232233                                }
     234
    233235                        } else {
    234236                                $message = __( 'This plugin has been closed and is no longer available for download.', 'wporg-plugins' );
    235237                        }