[wp-trac] Re: [WordPress Trac] #9313: Store the date format string "Y-m-d H:i:s" in a constant

WordPress Trac wp-trac at lists.automattic.com
Wed Mar 11 15:07:48 GMT 2009


#9313: Store the date format string "Y-m-d H:i:s" in a constant
---------------------------+------------------------------------------------
 Reporter:  simonwheatley  |       Owner:  anonymous             
     Type:  enhancement    |      Status:  new                   
 Priority:  low            |   Milestone:  Unassigned            
Component:  General        |     Version:                        
 Severity:  normal         |    Keywords:  has-patch, 2nd-opinion
---------------------------+------------------------------------------------
Changes (by simonwheatley):

  * priority:  normal => low


Comment:

 I accept this is a relatively minor issue, and that the world will keep
 turning either way. :) The pattern of using constants to specify date
 formats is, IMHO, a useful one and as I'm sure you're aware is even used
 in PHP 5
 (http://uk2.php.net/manual/en/class.datetime.php#datetime.constants.types).

 Re the misguided developer changing this constant and creating problems in
 places where they might not be looking... surely we expect out developers
 to be careful? If not, then surely this is what tests are for?

 (Updated patch to fix a stupid bug it introduced.)

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


More information about the wp-trac mailing list