Skip to:
Content

bbPress.org

Changeset 3569


Ignore:
Timestamp:
11/02/2011 06:17:17 PM (10 years ago)
Author:
johnjamesjacoby
Message:

Check query name in bbp_is_single_view(). See #1651, r3541. (2.1)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/plugin/bbp-includes/bbp-common-template.php

    r3568 r3569  
    537537 * @since bbPress (r2789)
    538538 *
    539  * @uses WP_Query Checks if WP_Query::bbp_is_view is true
     539 * @global WP_Query $wp_query To check if WP_Query::bbp_is_view is true
     540 * @uses bbp_get_query_name() To get the query name
    540541 * @return bool Is it a view page?
    541542 */
     
    548549    // Check query
    549550    if ( !empty( $wp_query->bbp_is_view ) && ( true == $wp_query->bbp_is_view ) )
    550         return true;
     551        $retval = true;
     552
     553    // Check query name
     554    if ( empty( $retval ) && bbp_is_query_name( 'bbp_single_view' ) )
     555        $retval = true;
    551556
    552557    return (bool) apply_filters( 'bbp_is_single_view', $retval );
Note: See TracChangeset for help on using the changeset viewer.