Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
07/14/2011 07:07:53 PM (13 years ago)
Author:
djpaul
Message:

Flip logic around for showing comment reply/edit buttons

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/bp-themes/bp-default/functions.php

    r4611 r4657  
    440440                <p>
    441441                    <?php
    442                         if ( current_user_can( 'edit_comment', get_comment_ID() ) )
     442                        if ( comments_open() )
    443443                            $links = get_comment_reply_link( array( 'depth' => $depth, 'max_depth' => $args['max_depth'] ) );
    444444                        else
     
    450450                </p>
    451451
    452                 <?php if ( comments_open() ) : ?>
     452                <?php if ( current_user_can( 'edit_comment', $comment->comment_ID ) ) : ?>
    453453                    <div class="comment-options"><?php printf( '<a class="comment-edit-link bp-secondary-action" href="%1$s" title="%2$s">%3$s</a> ', get_edit_comment_link( $comment->comment_ID ), esc_attr__( 'Edit comment', 'buddypress' ), __( 'Edit', 'buddypress' ) ) ?></div>
    454454                <?php endif; ?>
Note: See TracChangeset for help on using the changeset viewer.