Skip to:
Content

BuddyPress.org

Opened 12 years ago

Closed 12 years ago

#4906 closed defect (bug) (worksforme)

new message, wrong id...

Reported by: eggproject's profile eggproject Owned by:
Milestone: 1.6.2 Priority: normal
Severity: normal Version: 1.5
Component: Messages Keywords:
Cc:

Description

Hello...

I create bugfix bp-messages-classes.php
---
create a new message, but message id is wrong(current code setting thread id!)
---
bp-messages-classes.php
385 remove => $this->id = $wpdb->insert_id; because this thread_id!!!
367 insert =>
First insert the message into the messages table

if ( !$wpdb->query( $wpdb->prepare( "INSERT INTO {$bp->messages->table_name_messages} ( thread_id, sender_id, subject, message, date_sent ) VALUES ( %d, %d, %s, %s, %s )", $this->thread_id, $this->sender_id, $this->subject, $this->message, $this->date_sent ) ) )

return false;

$this->id = $wpdb->insert_id;

sry i little speak english :(

Change History (3)

#1 @johnjamesjacoby
12 years ago

  • Keywords needs-testing added
  • Milestone changed from Awaiting Review to 1.8
  • Version set to 1.5

Moving to 1.8.

#2 @ericlewis
12 years ago

Wasn't this fixed in r6413?

Related: #4597

#3 @r-a-y
12 years ago

  • Keywords needs-testing removed
  • Milestone changed from 1.8 to 1.6.2
  • Resolution set to worksforme
  • Severity changed from major to normal
  • Status changed from new to closed

ericlewis is correct.

Note: See TracTickets for help on using tickets.