[wp-trac] [WordPress Trac] #59636: Add meta to the revisions screen

WordPress Trac noreply at wordpress.org
Mon Feb 12 23:52:57 UTC 2024


#59636: Add meta to the revisions screen
-----------------------------+------------------------------
 Reporter:  adamsilverstein  |       Owner:  adamsilverstein
     Type:  enhancement      |      Status:  closed
 Priority:  normal           |   Milestone:
Component:  Revisions        |     Version:  6.4
 Severity:  normal           |  Resolution:  wontfix
 Keywords:  has-patch        |     Focuses:
-----------------------------+------------------------------

Comment (by jsmoriss):

 Replying to [comment:6 adamsilverstein]:
 > @jsmoriss
 >
 > Was this already resolved elsewhere?
 >
 > > 3 months ago
 > > Note that if anything else than a string is returned by
 _wp_post_revision_field_{$meta_key}, then PHP issues an error:
 >
 >
 > Reconsidering whether we should add this automatically - developers
 would be better suited to know what they want to display on this screen,
 core should only handle fields we add directly (eg. footnotes). Closing as
 Wontfix, please re-open if I have missed something or this is still
 desired.

 I don't think you understand the issue - plugin authors CANNOT add
 anything to this screen if the meta is not a string. A lot of plugin
 authors store values in arrays to optimize querying the post meta (one
 query vs many). If this isn't fixed, plugin authors cannot show the post
 meta differences if the post meta is an array.

 As a concrete example, these two filters cannot be enabled:

 https://github.com/surniaulula/wpsso/blob/main/lib/abstract/wp-
 meta.php#L176-L178

 js.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/59636#comment:8>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list