From: Aaron Schulz Date: Sat, 27 Apr 2019 04:40:53 +0000 (-0700) Subject: objectcache: micro-optimize determineKeyClassForStats() by using the limit option... X-Git-Tag: 1.34.0-rc.0~1849^2 X-Git-Url: http://git.cyclocoop.org/%22%20.%20generer_url_ecrire%28%22sites_tous%22%29%20.%20%22?a=commitdiff_plain;h=0394cb757a507b0985175625011717bb8df31ccf;p=lhc%2Fweb%2Fwiklou.git objectcache: micro-optimize determineKeyClassForStats() by using the limit option to explode() Change-Id: I7d95998487dd18078599b16201c9d0ec0debcb0b --- diff --git a/includes/libs/objectcache/WANObjectCache.php b/includes/libs/objectcache/WANObjectCache.php index 8f0b5398fa..dac3421786 100644 --- a/includes/libs/objectcache/WANObjectCache.php +++ b/includes/libs/objectcache/WANObjectCache.php @@ -2325,7 +2325,7 @@ class WANObjectCache implements IExpiringStore, LoggerAwareInterface { * @return string A collection name to describe this class of key */ protected function determineKeyClassForStats( $key ) { - $parts = explode( ':', $key ); + $parts = explode( ':', $key, 3 ); return $parts[1] ?? $parts[0]; // sanity }