Making WordPress.org

Ticket #2126: meta-2126.patch

File meta-2126.patch, 1.3 KB (added by SergeyBiryukov, 8 years ago)
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/support-forums/inc/class-ratings-compat.php

     
    349349        }
    350350
    351351        public function do_template_notice() {
     352                if ( $this->object->post_author == get_current_user_id() ) {
     353                        $notice = __( 'A review should be the review of an experience a user has with your project, not for self-promotion.', 'wporg-forums' ) . ' ';
     354
     355                        switch( $this->compat ) {
     356                                case 'plugin' :
     357                                        $notice .= __( 'Since you work on this plugin, please consider <em>not</em> leaving a review on your own work. You were probably going to give it five stars anyway.', 'wporg-forums' );
     358                                        break;
     359                                case 'theme' :
     360                                        $notice .= __( 'Since you work on this theme, please consider <em>not</em> leaving a review on your own work. You were probably going to give it five stars anyway.', 'wporg-forums' );
     361                                        break;
     362                        }
     363
     364                        echo '<p>' . $notice . '</p>';
     365                        return;
     366                }
     367
    352368                $report = $rate = '';
    353369                switch( $this->compat ) {
    354370                        case 'plugin' :