Changeset 1217
- Timestamp:
- 03/16/2009 11:52:10 AM (16 years ago)
- Location:
- trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/bp-blogs.php
r1209 r1217 726 726 // 727 727 728 function bp_blogs_delete_blogmeta( $blog_id, $meta_key = false, $meta_value = false ) {728 function bp_blogs_delete_blogmeta( $blog_id, $meta_key, $meta_value = false ) { 729 729 global $wpdb, $bp; 730 730 … … 739 739 $meta_value = trim( $meta_value ); 740 740 741 if ( !$meta_key ) { 742 $wpdb->query( $wpdb->prepare( "DELETE FROM {$bp->blogs->table_name_blogmeta} WHERE blog_id = %d", $blog_id ) ); 743 } else if ( !$meta_value ) { 741 if ( $meta_value ) { 744 742 $wpdb->query( $wpdb->prepare( "DELETE FROM {$bp->blogs->table_name_blogmeta} WHERE blog_id = %d AND meta_key = %s AND meta_value = %s", $blog_id, $meta_key, $meta_value ) ); 745 743 } else { -
trunk/bp-groups.php
r1209 r1217 2148 2148 // 2149 2149 2150 function groups_delete_groupmeta( $group_id, $meta_key = false, $meta_value = false ) {2150 function groups_delete_groupmeta( $group_id, $meta_key, $meta_value = false ) { 2151 2151 global $wpdb, $bp; 2152 2152 … … 2161 2161 $meta_value = trim( $meta_value ); 2162 2162 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 ) { 2166 2164 $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 ) ); 2167 2165 } else {
Note: See TracChangeset
for help on using the changeset viewer.