Skip to:
Content

bbPress.org


Ignore:
Timestamp:
02/28/2011 06:10:19 PM (15 years ago)
Author:
johnjamesjacoby
Message:

Use 'any' for post_parent in bbp-widgets.php to avoid conflict with '0' value.

File:
1 edited

Legend:

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

    r2938 r2939  
    333333        $max_shown    = !empty( $instance['max_shown']    ) ? (int) $instance['max_shown'] : 5;
    334334        $show_date    = !empty( $instance['show_date']    ) ? 'on'                         : false;
    335         $parent_forum = !empty( $instance['parent_forum'] ) ? $instance['parent_forum']    : 0;
     335        $parent_forum = !empty( $instance['parent_forum'] ) ? $instance['parent_forum']    : 'any';
    336336        $pop_check    = ( $instance['pop_check'] < $max_shown || empty( $instance['pop_check'] ) ) ? -1 : $instance['pop_check'];
    337337
     
    510510
    511511        $default = array(
    512             'post_parent'    => false,
     512            'post_parent'    => 'any',
    513513            'posts_per_page' => $max_shown,
    514514            'order'          => 'DESC'
Note: See TracChangeset for help on using the changeset viewer.