Skip to:
Content

bbPress.org


Ignore:
Timestamp:
07/17/2015 10:25:41 PM (8 years ago)
Author:
johnjamesjacoby
Message:

Prefer current_filter() over current_action() to maintain compatibility with WordPress versions older than 3.9. Fixes #2529.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/includes/topics/functions.php

    r5860 r5866  
    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            }
Note: See TracChangeset for help on using the changeset viewer.