[wp-trac] [WordPress Trac] #30210: WordPress generates unnecessary RSS feeds

WordPress Trac noreply at wordpress.org
Thu Nov 5 00:23:41 UTC 2015


#30210: WordPress generates unnecessary RSS feeds
-------------------------------------------------+-------------------------
 Reporter:  sergej.mueller                       |       Owner:
     Type:  defect (bug)                         |      Status:  new
 Priority:  normal                               |   Milestone:  Future
Component:  Feeds                                |  Release
 Severity:  normal                               |     Version:  4.0
 Keywords:  has-patch needs-testing needs-unit-  |  Resolution:
  tests                                          |     Focuses:
-------------------------------------------------+-------------------------

Comment (by stevenkword):

 I believe [attachment:30210.2.patch] solves the problem, but the solution
 isn't perfect.  Because the way the query is parsed in
 `$wp_query->parse_query`, both `$wp_query->is_feed()` and
 `$wp_query->is_tax()` can not simultaneously be true.  Currently,
 `is_tax()` will return false for all feeds.  This means in order to solve
 the case of empty but valid taxonomy archive feeds, we are not able to use
 the typical core functions.  As a work around, I'm checking to see if
 `$wp_query->tax_query` is an instance of the `WP_Tax_Query` object.

 The unit tests proposed in [attachment:30210.unit-test.patch] will
 struggle with the same `is_tax` symptoms and will need to be updated if we
 decide [attachment:30210.2.patch] is valid.

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


More information about the wp-trac mailing list