Browse Source

Using a more specific function to check for numbers on redis engine read

José Lorenzo Rodríguez 14 years ago
parent
commit
4958f0ee5d
1 changed files with 1 additions and 1 deletions
  1. 1 1
      lib/Cake/Cache/Engine/RedisEngine.php

+ 1 - 1
lib/Cake/Cache/Engine/RedisEngine.php

@@ -114,7 +114,7 @@ class RedisEngine extends CacheEngine {
  */
 	public function read($key) {
 		$value = $this->_Redis->get($key);
-		if (is_numeric($value)) {
+		if (ctype_digit($value)) {
 			$value = (int) $value;
 		}
 		if ($value !== false && is_string($value)) {