Skip to:
Content

BuddyPress.org

Changeset 10453


Ignore:
Timestamp:
01/17/2016 04:07:03 PM (9 years ago)
Author:
boonebgorges
Message:

Bail early from groups_post_update() if Activity is not active.

Props tw2113.
Fixes #6823.

File:
1 edited

Legend:

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

    r10445 r10453  
    894894 * Post an Activity status update affiliated with a group.
    895895 *
    896  * @todo Should bail out when the Activity component is not active.
    897  *
    898896 * @param array|string $args {
    899897 *     Array of arguments.
     
    904902 *                            update. Default: ID of the current group.
    905903 * }
    906  * @return int
     904 * @return int|bool Returns the ID of the new activity item on success, or false on failure.
    907905 */
    908906function groups_post_update( $args = '' ) {
     907    if ( ! bp_is_active( 'activity' ) ) {
     908        return false;
     909    }
     910
    909911    $bp = buddypress();
    910912
Note: See TracChangeset for help on using the changeset viewer.