Making WordPress.org


Ignore:
Timestamp:
09/07/2016 08:02:18 PM (9 years ago)
Author:
jmdodd
Message:

Support Forums: Remove topic title filter when not in the view template.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/support-forums/inc/class-ratings-compat.php

    r3997 r4001  
    4949        // Set up ratings view.
    5050        add_action( 'wporg_compat_before_single_view', array( $this, 'do_view_header' ) );
    51         add_filter( 'bbp_get_topic_title', array( $this, 'get_topic_title' ), 10, 2 );
    5251
    5352        // Add the topic form as either a new or edit form.
     
    120119            return;
    121120        }
     121
     122        // Add the filter for topic titles here.
     123        add_filter( 'bbp_get_topic_title', array( $this, 'get_topic_title' ), 10, 2 );
    122124        ?>
    123125<link itemprop="applicationCategory" href="http://schema.org/OtherApplication" />
     
    218220            return;
    219221        }
     222        remove_filter( 'bbp_get_topic_title', array( $this, 'get_topic_title' ), 10 );
    220223
    221224        if ( ! is_user_logged_in() ) {
Note: See TracChangeset for help on using the changeset viewer.