[wp-trac] [WordPress Trac] #13957: Check for $wp_rewrite in register_taxonomy and register_post_type

WordPress Trac wp-trac at lists.automattic.com
Thu Jun 17 22:48:43 UTC 2010


#13957: Check for $wp_rewrite in register_taxonomy and register_post_type
--------------------------+-------------------------------------------------
 Reporter:  nacin         |       Owner:       
     Type:  defect (bug)  |      Status:  new  
 Priority:  normal        |   Milestone:  3.0.1
Component:  Taxonomy      |     Version:  3.0  
 Severity:  normal        |    Keywords:       
--------------------------+-------------------------------------------------
 I'm noticing some people report errors like this:
 {{{
 Fatal error: Call to a member function add_rewrite_tag() on a non-object
 in
 /wp-includes/taxonomy.php on line 289
 }}}

 This plugin didn't work right in 2.9, but in 2.9 we checked $wp_rewrite
 for !empty() in register_taxonomy before calling add_rewrite_tag().

 I suggest we add back those sanity checks.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/13957>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list