[buddypress-trac] [BuddyPress Trac] #6515: Allow plugins to filter groups_format_notifications unmatched return values.
buddypress-trac
noreply at wordpress.org
Mon Jun 22 17:19:18 UTC 2015
#6515: Allow plugins to filter groups_format_notifications unmatched return
values.
---------------------------------------+--------------------
Reporter: dcavins | Owner:
Type: enhancement | Status: new
Priority: lowest | Milestone: 2.4
Component: Component - Notifications | Version: 2.3.2
Severity: trivial | Resolution:
Keywords: has-patch commit |
---------------------------------------+--------------------
Changes (by johnjamesjacoby):
* keywords: has-patch => has-patch commit
* milestone: Awaiting Review => 2.4
Comment:
Both patches seem good to me.
I agree that the `groups_format_notifications` action at the end is not
very helpful, especially considering every other condition returns
something, which means it only executes if nothing else happened.
It looks like this was addressed in the Friends component in
`friends_format_notifications` by using a `$return` value, but that still
doesn't explain to me why it's an action and not a filter.
These Notifications callbacks are pretty monolithic. Does it make sense to
also break these cases up into new functions?
`groups_format_notifications` for example is 650 lines long.
--
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/6515#comment:2>
BuddyPress Trac <http://buddypress.org/>
BuddyPress Trac
More information about the buddypress-trac
mailing list