﻿id,summary,reporter,owner,description,type,status,priority,milestone,component,version,severity,resolution,keywords,cc
13382,_wp_post_revision_fields filter is not very useful,mdawaffe,,"The _wp_post_revision_fields filter allows plugins to modify which post fields get revisioned (the default is title, content, excerpt).

It's pretty useless, though, since it's only run once and can't be changed by post_type.  A custom post type, for example, might only want to enable revisions on the content.

The _wp_post_revision_fields() is also a variation on the getter/setter pattern (static variable) we use in a few places to avoid globals.  It makes the function kind of crazy.

Proposal:  Split into two functions

{{{
@var int|object|array $post post_id or post object or post array
@return array Fields to revision: array( field => i18n'd label )
function wp_get_post_revision_fields( $post ) {
    // filter with _wp_post_revision_fields: pass post_id, post_type, ...?
    // don't cache results
}

@internal
@var array $past post array
@return array Filled $post array with revision info
function _wp_post_revision_fields( $post ) {
    $revisionable = wp_get_post_revision_fields( $post )
    // ...
}
}}}

I'd like to see this in 3.0 if we can, but marking as 3.1 for now.",enhancement,new,normal,Future Release,Revisions,3.0,normal,,needs-patch,
