Skip to:
Content
Pages
Categories
Search
Top
Bottom

Re: External Group Blogs bug

i notified Andy of this problem, but here is my fix – needs to hash the post link (but this would leave to problems when removing a feed and the activity not deleting)

/* Fetch an existing activity_id if one exists. */
if ( function_exists( 'bp_activity_get_activity_id' ) )
$id = bp_activity_get_activity_id( array( 'user_id' => false, 'component' => $bp->groups->id, 'type' => 'exb', 'item_id' => $group_id, 'secondary_item_id' => wp_hash( $post['link'] ) ) );

/* Record or update in activity streams. */
groups_record_activity( array(
'id' => $id,
'user_id' => false,
'action' => $activity_action,
'content' => $activity_content,
'primary_link' => $post['link'],
'type' => 'exb',
'item_id' => $group_id,
'secondary_item_id' => wp_hash( $post['link'] ),
'recorded_time' => gmdate( "Y-m-d H:i:s", $post_date ),
'hide_sitewide' => $hide_sitewide
) );

Skip to toolbar