[wp-trac] [WordPress Trac] #15460: Feed format parameter for is_feed()

WordPress Trac wp-trac at lists.automattic.com
Thu Nov 18 03:05:47 UTC 2010


#15460: Feed format parameter for is_feed()
-------------------------+--------------------------------------------------
 Reporter:  johnbillion  |       Owner:           
     Type:  enhancement  |      Status:  new      
 Priority:  normal       |   Milestone:  3.1      
Component:  Feeds        |     Version:           
 Severity:  normal       |    Keywords:  has-patch
-------------------------+--------------------------------------------------

Comment(by nacin):

 Looks good. I'm making a few changes. Patch attached.

 In line with is_singular() and a few others, I'm allowing this to accept
 an array to check.

 Additionally, instead of get_query_var(), we need to use $this->get(). The
 point of moving the functions to methods is they always reflect the
 WP_Query object in question, not necessarily $wp_query.

 Added docs and cleaned up the logic a little. The method's parameter also
 needs to be optional.

 We also need to account for the query var being 'feed', if no feed is
 specified, which we'll need to catch by checking the default feed too.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/15460#comment:3>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list