WordPress.org

Make WordPress Core

Changeset 26313


Ignore:
Timestamp:
11/22/2013 01:59:43 AM (6 years ago)
Author:
dd32
Message:

Use static strings instead of a impossible-to-translate string in the Automatic updates debug email. Props SergeyBiryukov. Fixes #25667

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/includes/class-wp-upgrader.php

    r26279 r26313  
    23472347            $success_items = wp_list_filter( $this->update_results[ $type ], array( 'result' => true ) );
    23482348            if ( $success_items ) {
    2349                 /* translators: %s singular/plural form of 'plugin', 'theme', or, 'translation' */
    2350                 $body[] = sprintf( __( 'The following %ss were successfully updated:' ), $type );
     2349                $messages = array(
     2350                    'plugin'      => __( 'The following plugins were successfully updated:' ),
     2351                    'theme'       => __( 'The following themes were successfully updated:' ),
     2352                    'translation' => __( 'The following translations were successfully updated:' ),
     2353                );
     2354
     2355                $body[] = $messages[ $type ];
    23512356                foreach ( wp_list_pluck( $success_items, 'name' ) as $name ) {
    23522357                    $body[] = ' * ' . sprintf( __( 'SUCCESS: %s' ), $name );
     
    23552360            if ( $success_items != $this->update_results[ $type ] ) {
    23562361                // Failed updates
    2357                 /* translators: %s generic singular/plural form of 'plugin', 'theme', or, 'translation' */
    2358                 $body[] = sprintf( __( 'The following %ss failed to update:' ), $type );
     2362                $messages = array(
     2363                    'plugin'      => __( 'The following plugins failed to update:' ),
     2364                    'theme'       => __( 'The following themes failed to update:' ),
     2365                    'translation' => __( 'The following translations failed to update:' ),
     2366                );
     2367
     2368                $body[] = $messages[ $type ];
    23592369                foreach ( $this->update_results[ $type ] as $item ) {
    23602370                    if ( ! $item->result || is_wp_error( $item->result ) ) {
Note: See TracChangeset for help on using the changeset viewer.