[wp-trac] [WordPress Trac] #29109: Problem found with wp-includes/posts.php
WordPress Trac
noreply at wordpress.org
Mon Aug 4 15:39:00 UTC 2014
#29109: Problem found with wp-includes/posts.php
-------------------------------+------------------------------
Reporter: LewisCowles | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Posts, Post Types | Version: 3.9.1
Severity: normal | Resolution:
Keywords: reporter-feedback | Focuses:
-------------------------------+------------------------------
Comment (by LewisCowles):
also as it has been pointed out that it should be receiving an array, I
have updated my proposed fix to the below...
{{{
if( is_array($args->taxonomies) ){
foreach ( $args->taxonomies as $taxonomy ) {
register_taxonomy_for_object_type( $taxonomy, $post_type );
}
} else {
trigger_error('Invalid input for taxonomies in register
post_type', E_USER_NOTICE);
}
}}}
I Believe this would be a more suitable piece of code, although I concede
that E_USER_NOTICE is my personal preference
--
Ticket URL: <https://core.trac.wordpress.org/ticket/29109#comment:5>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list