Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
08/06/2013 01:18:04 PM (11 years ago)
Author:
boonebgorges
Message:

Fix PHP notice in groups_screen_group_admin_settings()

To support legacy group edit templates, we must check to see that
$_POSTgroup-invite-status? is populated before sanitizing the value
against our status whitelist.

Fixes #5132

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/bp-groups/bp-groups-screens.php

    r7212 r7343  
    564564        // Checked against a whitelist for security
    565565        $allowed_invite_status = apply_filters( 'groups_allowed_invite_status', array( 'members', 'mods', 'admins' ) );
    566         $invite_status         = in_array( $_POST['group-invite-status'], (array) $allowed_invite_status ) ? $_POST['group-invite-status'] : 'members';
     566        $invite_status         = isset( $_POST['group-invite-status'] ) && in_array( $_POST['group-invite-status'], (array) $allowed_invite_status ) ? $_POST['group-invite-status'] : 'members';
    567567
    568568        // Check the nonce
Note: See TracChangeset for help on using the changeset viewer.