[buddypress-trac] [BuddyPress Trac] #3083: Create message meta table and appropriate meta functions

buddypress-trac noreply at wordpress.org
Thu Nov 20 01:43:36 UTC 2014


#3083: Create message meta table and appropriate meta functions
-------------------------+-----------------------
 Reporter:  r-a-y        |       Owner:  r-a-y
     Type:  enhancement  |      Status:  assigned
 Priority:  normal       |   Milestone:  2.2
Component:  Messaging    |     Version:  1.5
 Severity:  normal       |  Resolution:
 Keywords:  has-patch    |
-------------------------+-----------------------

Comment (by boonebgorges):

 r-a-y - Thanks for working on this! Looks pretty good.

 * There's some copypasta to be cleaned up - mostly in the docblocks, but
 see also the 'cache_key_prefix' in the meta prefetcher
 * The places where you've chosen to prefetch meta look good to me, as do
 the 'update_meta_cache' arguments.
 * You set 'update_meta_cache' to false in the inbox, with a note asking
 for feedback. My feedback: Don't :) I have no idea if anyone will actually
 use messagemeta in the inbox, but it's such a minor bit of overhead that I
 see no reason why we shouldn't prefetch it for every display loop.
 * I know you're going to work on unit tests, but I just wanted to add that
 the places where I'd most like to see them are surrounding the cache pre-
 fetch and the changes to `delete()`
 * On that note: passing an array of message_ids to
 'messages_thread_deleted_thread' might break things. I know it's very
 unlikely that anyone is using this hook, but still, I think it's safest
 (and in keeping with the singular name of the hook) to loop through and
 fire it for each deleted message ID. You can also add a separate plural
 action if you want.

 This will be pretty sweet!

--
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/3083#comment:8>
BuddyPress Trac <http://buddypress.org/>
BuddyPress Trac


More information about the buddypress-trac mailing list