[wp-trac] [WordPress Trac] #56198: Check cache key type

WordPress Trac noreply at wordpress.org
Sun Jul 17 20:50:07 UTC 2022


#56198: Check cache key type
-------------------------+--------------------------
 Reporter:  tillkruess   |       Owner:  (none)
     Type:  enhancement  |      Status:  new
 Priority:  normal       |   Milestone:  6.1
Component:  Cache API    |     Version:  trunk
 Severity:  normal       |  Resolution:
 Keywords:  has-patch    |     Focuses:  performance
-------------------------+--------------------------

Comment (by tillkruess):

 Replying to [comment:14 malthert]:

 > I tested with PHP 5.6.40 and could not reproduce such an issue. There is
 no extra variable needed: (same result for PHP 5.6, 7.4 and 8.1)

 I could swear this used to be a thing.

 Anyhow, would it not make sense to check the group similar to
 `is_valid_key()`, since `"0"` is technically a valid group, but fail with
 `empty(trim('0'))`?

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


More information about the wp-trac mailing list