Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
03/09/2024 10:55:43 AM (16 months ago)
Author:
imath
Message:

BP Standalone Block Themes: adapt Groups template hierarchy

  • Adds a members/single/index.html root template to the BP Standalone Theme hierarchy to be used by BP Standalone Block Themes in respect of WP Block Themes templating logic.
  • Adds a groups/single/index.html root template to the BP Standalone Theme hierarchy to be used by BP Standalone Block Themes in respect of WP Block Themes templating logic.

See #9118
See https://github.com/buddypress/buddypress/pull/249
See https://github.com/buddypress/buddyvibes/pull/7

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-groups/screens/single/admin/delete-group.php

    r13503 r13762  
    1212 *
    1313 * @since 1.0.0
     14 *
     15 * @return void
    1416 */
    1517function groups_screen_group_admin_delete_group() {
    1618
    1719    if ( 'delete-group' != bp_get_group_current_admin_tab() ) {
    18         return false;
     20        return;
    1921    }
    2022
    2123    if ( ! bp_is_item_admin() && ! bp_current_user_can( 'bp_moderate' ) ) {
    22         return false;
     24        return;
    2325    }
    2426
     
    3133        // Check the nonce first.
    3234        if ( ! check_admin_referer( 'groups_delete_group' ) ) {
    33             return false;
     35            return;
    3436        }
    3537
     
    7173    do_action( 'groups_screen_group_admin_delete_group', $bp->groups->current_group->id );
    7274
    73     /**
    74      * Filters the template to load for the Delete Group page.
    75      *
    76      * @since 1.0.0
    77      *
    78      * @param string $value Path to the Delete Group template.
    79      */
    80     bp_core_load_template( apply_filters( 'groups_template_group_admin_delete_group', 'groups/single/home' ) );
     75    $templates = array(
     76        /**
     77         * Filters the template to load for the Delete Group page.
     78         *
     79         * @since 1.0.0
     80         *
     81         * @param string $value Path to the Delete Group template.
     82         */
     83        apply_filters( 'groups_template_group_admin_delete_group', 'groups/single/home' ),
     84        'groups/single/index',
     85    );
     86
     87    bp_core_load_template( $templates );
    8188}
    8289add_action( 'bp_screens', 'groups_screen_group_admin_delete_group' );
Note: See TracChangeset for help on using the changeset viewer.