[wp-trac] [WordPress Trac] #21327: No default value is set for $group in WP_Object_Cache for the decr method

WordPress Trac wp-trac at lists.automattic.com
Fri Jul 20 19:50:23 UTC 2012


#21327: No default value is set for $group in WP_Object_Cache for the decr method
-----------------------------+-----------------------------
 Reporter:  bananastalktome  |      Owner:
     Type:  defect (bug)     |     Status:  new
 Priority:  normal           |  Milestone:  Awaiting Review
Component:  Cache            |    Version:
 Severity:  normal           |   Keywords:  has-patch
-----------------------------+-----------------------------
 Unlike {{{incr}}} and other methods on {{{WP_Object_Cache}}}, {{{decr}}}
 does not do a check to see if {{{$group}}} is empty to set it to
 {{{'default'}}}. This is problematic when using {{{wp_cache_decr()}}}
 since the result is that set cache with {{{wp_cache_set}}} (which has
 {{{$group}}} set as {{{'default'}}}) is not decremented.

 Patch included, but not sure if this should be classified 'normal' or
 'major'. Unit tests still appear to pass, but more testing probably
 useful.

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


More information about the wp-trac mailing list