Ticket #6969: 6969.02.patch
File 6969.02.patch, 1.2 KB (added by , 9 years ago) |
---|
-
src/bp-friends/classes/class-bp-friends-friendship.php
106 106 $this->is_request = $is_request; 107 107 108 108 if ( !empty( $id ) ) { 109 $this->id = $id;109 $this->id = (int) $id; 110 110 $this->populate_friend_details = $populate_friend_details; 111 111 $this->populate( $this->id ); 112 112 } … … 123 123 $bp = buddypress(); 124 124 125 125 if ( $friendship = $wpdb->get_row( $wpdb->prepare( "SELECT * FROM {$bp->friends->table_name} WHERE id = %d", $this->id ) ) ) { 126 $this->initiator_user_id = $friendship->initiator_user_id;127 $this->friend_user_id = $friendship->friend_user_id;128 $this->is_confirmed = $friendship->is_confirmed;129 $this->is_limited = $friendship->is_limited;126 $this->initiator_user_id = (int) $friendship->initiator_user_id; 127 $this->friend_user_id = (int) $friendship->friend_user_id; 128 $this->is_confirmed = (int) $friendship->is_confirmed; 129 $this->is_limited = (int) $friendship->is_limited; 130 130 $this->date_created = $friendship->date_created; 131 131 } 132 132