Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
04/20/2017 12:19:36 AM (7 years ago)
Author:
dcavins
Message:

Add 'status' parameter to BP_Groups_Group::get().

Add $status parameter to groups_get_groups()` and its underlying
function BP_Groups_Group::get(). Find groups by passing a single
status, a comma-separated list of statuses, or any array of statuses.

Fixes #7501.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-groups/bp-groups-functions.php

    r11530 r11532  
    718718        'meta_query'         => false,          // Filter by groupmeta. See WP_Meta_Query for syntax.
    719719        'show_hidden'        => false,          // Show hidden groups to non-admins.
     720        'status'             => array(),        // Array or comma-separated list of group statuses to limit results to.
    720721        'per_page'           => 20,             // The number of results to return per page.
    721722        'page'               => 1,              // The page to return if limiting per page.
     
    740741        'meta_query'         => $r['meta_query'],
    741742        'show_hidden'        => $r['show_hidden'],
     743        'status'             => $r['status'],
    742744        'per_page'           => $r['per_page'],
    743745        'page'               => $r['page'],
Note: See TracChangeset for help on using the changeset viewer.