Making WordPress.org

Changeset 5036


Ignore:
Timestamp:
03/01/2017 11:46:08 PM (10 years ago)
Author:
coffee2code
Message:

Plugin Directory Theme: Correct the reversed Favorite %s/Unfavorite %s strings.

Also add translator comments.

Props SergeyBiryukov.
See #2534.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-plugins/template-parts/plugin-single.php

    r4568 r5036  
    7373                                        <a href="<?php echo esc_url( $url ); ?>" class="plugin-favorite-heart<?php echo $is_favorited ? ' favorited' : ''; ?>">
    7474                                                <span class="screen-reader-text">
    75                                                         <?php printf( $is_favorited ? __( 'Favorite %s' ) : __( 'Unfavorite %s' ), get_the_title() ); ?>
     75                                                        <?php
     76                                                                if ( $is_favorited ) {
     77                                                                        /* translators: %s: plugin name */
     78                                                                        printf( __( 'Unfavorite %s', 'wporg-plugins' ), get_the_title() );
     79                                                                } else {
     80                                                                        /* translators: %s: plugin name */
     81                                                                        printf( __( 'Favorite %s', 'wporg-plugins' ), get_the_title() );
     82                                                                }
     83                                                        ?>
    7684                                                </span>
    7785                                        </a>
Note: See TracChangeset for help on using the changeset viewer.