diff --git a/composer.json b/composer.json index a851fe6..5c6d433 100644 --- a/composer.json +++ b/composer.json @@ -15,7 +15,7 @@ "require": { "ext-mbstring": "*", "ext-json": "*", - "predis/predis": "v1.1.9", + "predis/predis": "v2.3.0", "paragonie/random_compat": ">=2" }, "minimum-stability": "stable", diff --git a/composer.lock b/composer.lock index 41f9438..f724f31 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "ad3fb9bfb043b086870b317dc9eff9b7", + "content-hash": "401ff61cebe5223d003a47192d7c3d6a", "packages": [ { "name": "paragonie/random_compat", @@ -58,27 +58,28 @@ }, { "name": "predis/predis", - "version": "v1.1.9", + "version": "v2.3.0", "source": { "type": "git", "url": "https://github.com/predis/predis.git", - "reference": "c50c3393bb9f47fa012d0cdfb727a266b0818259" + "reference": "bac46bfdb78cd6e9c7926c697012aae740cb9ec9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/predis/predis/zipball/c50c3393bb9f47fa012d0cdfb727a266b0818259", - "reference": "c50c3393bb9f47fa012d0cdfb727a266b0818259", + "url": "https://api.github.com/repos/predis/predis/zipball/bac46bfdb78cd6e9c7926c697012aae740cb9ec9", + "reference": "bac46bfdb78cd6e9c7926c697012aae740cb9ec9", "shasum": "" }, "require": { - "php": ">=5.3.9" + "php": "^7.2 || ^8.0" }, "require-dev": { - "phpunit/phpunit": "~4.8" + "friendsofphp/php-cs-fixer": "^3.3", + "phpstan/phpstan": "^1.9", + "phpunit/phpunit": "^8.0 || ^9.4" }, "suggest": { - "ext-curl": "Allows access to Webdis when paired with phpiredis", - "ext-phpiredis": "Allows faster serialization and deserialization of the Redis protocol" + "ext-relay": "Faster connection with in-memory caching (>=0.6.2)" }, "type": "library", "autoload": { @@ -91,19 +92,13 @@ "MIT" ], "authors": [ - { - "name": "Daniele Alessandri", - "email": "suppakilla@gmail.com", - "homepage": "http://clorophilla.net", - "role": "Creator & Maintainer" - }, { "name": "Till Krüss", "homepage": "https://till.im", "role": "Maintainer" } ], - "description": "Flexible and feature-complete Redis client for PHP and HHVM", + "description": "A flexible and feature-complete Redis client for PHP.", "homepage": "http://github.com/predis/predis", "keywords": [ "nosql", @@ -112,7 +107,7 @@ ], "support": { "issues": "https://github.com/predis/predis/issues", - "source": "https://github.com/predis/predis/tree/v1.1.9" + "source": "https://github.com/predis/predis/tree/v2.3.0" }, "funding": [ { @@ -120,16 +115,19 @@ "type": "github" } ], - "time": "2021-10-05T19:02:38+00:00" + "time": "2024-11-21T20:00:02+00:00" } ], "packages-dev": [], "aliases": [], "minimum-stability": "stable", - "stability-flags": [], + "stability-flags": {}, "prefer-stable": false, "prefer-lowest": false, - "platform": [], - "platform-dev": [], - "plugin-api-version": "2.1.0" + "platform": { + "ext-mbstring": "*", + "ext-json": "*" + }, + "platform-dev": {}, + "plugin-api-version": "2.6.0" } diff --git a/includes/common.inc.php b/includes/common.inc.php index c13424b..a92a3ed 100644 --- a/includes/common.inc.php +++ b/includes/common.inc.php @@ -95,20 +95,20 @@ $server['keys'] = $config['keys']; } -if (!isset($config['scansize'])) { - $config['scansize'] = 1000; -} - -if (!isset($config['scanmax'])) { - $config['scanmax'] = 0; -} - if (!isset($server['scansize'])) { - $server['scansize'] = $config['scansize']; + if (isset($config['scansize'])) { + $server['scansize'] = $config['scansize']; + } else { + $server['scansize'] = 1000; + } } if (!isset($server['scanmax'])) { - $server['scanmax'] = $config['scanmax']; + if (isset($config['scanmax'])) { + $server['scanmax'] = $config['scanmax']; + } else { + $server['scanmax'] = 0; + } } if (!isset($server['serialization'])) { @@ -125,8 +125,8 @@ $config['showEmptyNamespaceAsKey'] = false; } -if (!isset($config['scheme']) || empty($config['scheme'])) { - $config['scheme'] = 'tcp'; +if (!isset($server['scheme']) || empty($server['scheme'])) { + $server['scheme'] = 'tcp'; } // Setup a connection to Redis.