[buddypress-trac] [BuddyPress Trac] #7834: WordPress Changeset 42836 introduces conflict with BuddyPress `blogmeta` table

buddypress-trac noreply at wordpress.org
Fri May 18 16:05:56 UTC 2018


#7834: WordPress Changeset 42836 introduces conflict with BuddyPress `blogmeta`
table
--------------------------+---------------------
 Reporter:  needle        |       Owner:  (none)
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  3.1
Component:  Blogs         |     Version:
 Severity:  normal        |  Resolution:
 Keywords:  dev-feedback  |
--------------------------+---------------------

Comment (by r-a-y):

 Thanks for the feedback, @imath.

 > Instead of prefixing the table name, the meta keys could be BP prefixed
 if there are some fears to introduce a mess with plugins that could use
 similar meta key names :)

 We do need to prefix the table name if we're keeping a separate blog meta
 table due to how WordPress looks for the global property in the `$wpdb`
 global in `_get_meta_table()`:
 https://core.trac.wordpress.org/browser/branches/4.9/src/wp-
 includes/meta.php?marks=42,47,904#L889

 However, if we decide to migrate our data to WP's blog meta table, then
 prefixing the meta key should be doable. When we do the migration, we
 would change all our meta keys to add our prefix.  Then in our blog meta
 functions, we would just automatically add the prefix during lookups to
 avoid breaking existing blog meta entries.

 > I also think, it could be a nice opportunity to have an upgrade tool to
 fix some other areas like favorites one of these days 😉

 Agreed!

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


More information about the buddypress-trac mailing list