Skip to:
Content

bbPress.org

Ticket #2529: 2529.7.diff

File 2529.7.diff, 1.1 KB (added by netweb, 9 years ago)
  • src/includes/replies/functions.php

     
    929929
    930930                        // Make every effort to get topic id
    931931                        // https://bbpress.trac.wordpress.org/ticket/2529
    932                         if ( empty( $topic_id ) && ( current_action() === 'bbp_deleted_reply' ) ) {
     932                        if ( empty( $topic_id ) && ( current_filter() === 'bbp_deleted_reply' ) ) {
    933933                                $topic_id = get_post_field( 'post_parent', $reply_id );
    934934                        }
    935935                }
  • src/includes/topics/functions.php

     
    964964
    965965                        // Make every effort to get forum id
    966966                        // https://bbpress.trac.wordpress.org/ticket/2529
    967                         if ( empty( $forum_id ) && ( current_action() === 'bbp_deleted_topic' ) ) {
     967                        if ( empty( $forum_id ) && ( current_filter() === 'bbp_deleted_topic' ) ) {
    968968                                $forum_id = get_post_field( 'post_parent', $topic_id );
    969969                        }
    970970                }