Skip to:

Opened 13 years ago

Closed 13 years ago

#3434 closed defect (bug) (fixed)

$secondary_item_id is no longer optional in delete_for_user_by_item_id

Reported by: enderandrew's profile enderandrew Owned by:
Milestone: 1.5 Priority: normal
Severity: normal Version: 1.5
Component: Core Keywords:


As per the comment for this function:

  • @param integer $secondary_item_id (optional) The secondary item id of the notifications that we wish to use to delete.

The function changed from:

function delete_for_user_by_item_id( $user_id, $item_id, $component_name, $component_action, $secondary_item_id = false )


function delete_for_user_by_item_id( $user_id, $item_id, $component_name, $component_action, $secondary_item_id = false )

So now you can't call this function without passing a fifth parameter, which breaks plugins. If this change was intentional, the comment/description for the function needs to change.

Change History (2)

#1 @boonebgorges
13 years ago

  • Milestone changed from Awaiting Review to 1.5

I'm not seeing where it was every $secondary_item_id = false

However, there is a bit of logic in the function that accounts for the case where it's not passed. So it makes sense to put a default value in there.

#2 @boonebgorges
13 years ago

  • Resolution set to fixed
  • Status changed from new to closed

(In [4922]) Makes secondary_item_id param truly optional in BP_Core_Notification::delete_for_user_by_item_id(). Fixes #3434. Props enderandrew

Note: See TracTickets for help on using tickets.