Skip to:
Content

BuddyPress.org

Changeset 11783


Ignore:
Timestamp:
01/02/2018 03:12:48 PM (7 years ago)
Author:
djpaul
Message:

Remove uses of bp_is_active( 'forums' ).

These checks only works with the Legacy forums, not bbPress.
All template and navigation functionality affected by this changeset have replacements directly provided by bbPress.

See #5351

Location:
trunk/src
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-groups/classes/class-bp-groups-component.php

    r11776 r11783  
    556556            }
    557557
    558             // Forums are enabled and turned on.
    559             if ( $this->current_group->enable_forum && bp_is_active( 'forums' ) ) {
    560                 $sub_nav[] = array(
    561                     'name'            => _x( 'Forum', 'My Group screen nav', 'buddypress' ),
    562                     'slug'            => 'forum',
    563                     'parent_url'      => $group_link,
    564                     'parent_slug'     => $this->current_group->slug,
    565                     'screen_function' => 'groups_screen_group_forum',
    566                     'position'        => 40,
    567                     'user_has_access' => $this->current_group->user_has_access,
    568                     'item_css_id'     => 'forums'
    569                 );
    570             }
    571 
    572558            if ( $this->current_group->front_template || bp_is_active( 'activity' ) ) {
    573559                /**
  • trunk/src/bp-templates/bp-legacy/buddypress/groups/create.php

    r11763 r11783  
    190190                </fieldset>
    191191
    192                 <?php if ( bp_is_active( 'forums' ) ) : ?>
    193 
    194                     <h4><?php _e( 'Group Forums', 'buddypress' ); ?></h4>
    195 
    196                     <p><?php _e( 'Should this group have a forum?', 'buddypress' ); ?></p>
    197 
    198                     <div class="checkbox">
    199                         <label for="group-show-forum"><input type="checkbox" name="group-show-forum" id="group-show-forum" value="1"<?php checked( bp_get_new_group_enable_forum(), true, true ); ?> /> <?php _e( 'Enable discussion forum', 'buddypress' ); ?></label>
    200                     </div>
    201 
    202                 <?php endif; ?>
    203 
    204192                <?php
    205193
  • trunk/src/bp-templates/bp-legacy/buddypress/groups/single/admin/group-settings.php

    r11763 r11783  
    1919 */
    2020do_action( 'bp_before_group_settings_admin' ); ?>
    21 
    22 <?php if ( bp_is_active( 'forums' ) ) : ?>
    23 
    24     <div class="checkbox">
    25         <label for="group-show-forum"><input type="checkbox" name="group-show-forum" id="group-show-forum" value="1"<?php bp_group_show_forum_setting(); ?> /> <?php _e( 'Enable discussion forum', 'buddypress' ); ?></label>
    26     </div>
    27 
    28     <hr />
    29 
    30 <?php endif; ?>
    3121
    3222<fieldset class="group-create-privacy">
Note: See TracChangeset for help on using the changeset viewer.