[wp-trac] [WordPress Trac] #11631: php code improvements get_the_title() and get_post()

WordPress Trac wp-trac at lists.automattic.com
Mon Mar 1 06:10:58 UTC 2010


#11631: php code improvements get_the_title() and get_post()
--------------------------+-------------------------------------------------
 Reporter:  hakre         |       Owner:           
     Type:  enhancement   |      Status:  new      
 Priority:  normal        |   Milestone:  3.0      
Component:  Optimization  |     Version:  2.9      
 Severity:  normal        |    Keywords:  has-patch
--------------------------+-------------------------------------------------

Comment(by nacin):

 The stuff in get_the_title() does not appear to be code improvements in
 any way. We're making more variable assignments we don't need to be doing,
 and new isset() checks, and we're calling is_admin() twice now, and we're
 now checking for $format. Sure, it looks more compact, but that's not what
 we're going for.

 Same with get_post(), though less so. None of this seems necessary.

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


More information about the wp-trac mailing list