Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
03/28/2020 01:31:24 PM (5 years ago)
Author:
imath
Message:

BP Activity: add missing /* translators */ comments

See #8260

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-activity/classes/class-bp-akismet.php

    r11950 r12586  
    9393            $who = bp_activity_get_meta( $activity['id'], '_bp_akismet_user' );
    9494
    95             if ( 'true' == $user_result )
     95            if ( 'true' == $user_result ) {
     96                /* translators: %s: the name of the user */
    9697                $desc = sprintf( __( 'Flagged as spam by %s', 'buddypress' ), $who );
    97             else
     98            } else {
     99                /* translators: %s: the name of the user */
    98100                $desc = sprintf( __( 'Un-spammed by %s', 'buddypress' ), $who );
     101            }
    99102        }
    100103
     
    443446            return;
    444447
    445         $this->update_activity_history( $activity->id, sprintf( __( '%s reported this activity as spam', 'buddypress' ), bp_get_loggedin_user_username() ), 'report-spam' );
     448        $this->update_activity_history(
     449            $activity->id,
     450            sprintf(
     451                /* translators: %s: the current user username */
     452                __( '%s reported this activity as spam', 'buddypress' ),
     453                bp_get_loggedin_user_username()
     454            ),
     455            'report-spam'
     456        );
     457
    446458        bp_activity_update_meta( $activity->id, '_bp_akismet_user_result', 'true' );
    447459        bp_activity_update_meta( $activity->id, '_bp_akismet_user', bp_get_loggedin_user_username() );
     
    460472            return;
    461473
    462         $this->update_activity_history( $activity->id, sprintf( __( '%s reported this activity as not spam', 'buddypress' ), bp_get_loggedin_user_username() ), 'report-ham' );
     474        $this->update_activity_history(
     475            $activity->id,
     476            sprintf(
     477                /* translators: %s: the current user username */
     478                __( '%s reported this activity as not spam', 'buddypress' ),
     479                bp_get_loggedin_user_username()
     480            ),
     481            'report-ham'
     482        );
     483
    463484        bp_activity_update_meta( $activity->id, '_bp_akismet_user_result', 'false' );
    464485        bp_activity_update_meta( $activity->id, '_bp_akismet_user', bp_get_loggedin_user_username() );
     
    494515        } else {
    495516            bp_activity_update_meta( $activity->id, '_bp_akismet_error', bp_core_current_time() );
    496             $this->update_activity_history( $activity->id, sprintf( __( 'Akismet was unable to check this item (response: %s), will automatically retry again later.', 'buddypress' ), $this->last_activity->akismet_submission['bp_as_result'] ), 'check-error' );
     517            $this->update_activity_history(
     518                $activity->id,
     519                sprintf(
     520                    /* translators: %s the akismet result */
     521                    __( 'Akismet was unable to check this item (response: %s), will automatically retry again later.', 'buddypress' ),
     522                    $this->last_activity->akismet_submission['bp_as_result']
     523                ),
     524                'check-error'
     525            );
    497526        }
    498527
     
    619648
    620649        echo '<div class="akismet-history"><div>';
     650        /* translators: 1: the human diff time. 2: the akismet history data. */
    621651        printf( _x( '%1$s &mdash; %2$s', 'x hours ago - akismet cleared this item', 'buddypress' ), '<span>' . bp_core_time_since( $history[2] ) . '</span>', esc_html( $history[1] ) );
    622652        echo '</div></div>';
Note: See TracChangeset for help on using the changeset viewer.