Skip to:
Content

BuddyPress.org

Changeset 1217 for trunk/bp-groups.php


Ignore:
Timestamp:
03/16/2009 11:52:10 AM (15 years ago)
Author:
apeatling
Message:

FIxes #589 props johnbillion.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/bp-groups.php

    r1209 r1217  
    21482148//
    21492149
    2150 function groups_delete_groupmeta( $group_id, $meta_key = false, $meta_value = false ) {
     2150function groups_delete_groupmeta( $group_id, $meta_key, $meta_value = false ) {
    21512151    global $wpdb, $bp;
    21522152   
     
    21612161    $meta_value = trim( $meta_value );
    21622162
    2163     if ( !$meta_key ) {
    2164         $wpdb->query( $wpdb->prepare( "DELETE FROM " . $bp->groups->table_name_groupmeta . " WHERE group_id = %d", $group_id ) );       
    2165     } else if ( !$meta_value ) {
     2163    if ( $meta_value ) {
    21662164        $wpdb->query( $wpdb->prepare( "DELETE FROM " . $bp->groups->table_name_groupmeta . " WHERE group_id = %d AND meta_key = %s AND meta_value = %s", $group_id, $meta_key, $meta_value ) );
    21672165    } else {
Note: See TracChangeset for help on using the changeset viewer.