From 7c71e6af388b2190bc4ba0937a11dd74b63f64e1 Mon Sep 17 00:00:00 2001 From: John Spellman Date: Fri, 2 Dec 2022 14:08:59 -0700 Subject: [PATCH] [BUGS-5583] Release 1.3.1 (#379) --- .github/dependabot.yml | 2 ++ README.md | 10 ++++++++-- object-cache.php | 25 +++++++++++++++++++++++++ package-lock.json | 2 +- package.json | 2 +- readme.txt | 8 ++++++-- wp-redis.php | 2 +- 7 files changed, 44 insertions(+), 7 deletions(-) diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 4342d12..92041ae 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -6,6 +6,7 @@ updates: interval: weekly timezone: America/Los_Angeles day: tuesday + target-branch: "develop" open-pull-requests-limit: 99 ignore: - dependency-name: phpunit/phpunit @@ -22,4 +23,5 @@ updates: interval: weekly timezone: America/Los_Angeles day: tuesday + target-branch: "develop" open-pull-requests-limit: 99 diff --git a/README.md b/README.md index 41599ff..74804f7 100644 --- a/README.md +++ b/README.md @@ -4,8 +4,8 @@ **Contributors:** [getpantheon](https://profiles.wordpress.org/getpantheon), [danielbachhuber](https://profiles.wordpress.org/danielbachhuber), [mboynes](https://profiles.wordpress.org/mboynes), [Outlandish Josh](https://profiles.wordpress.org/Outlandish Josh) **Tags:** cache, plugin, redis **Requires at least:** 3.0.1 -**Tested up to:** 5.9 -**Stable tag:** 1.3.0 +**Tested up to:** 6.1.1 +**Stable tag:** 1.3.1 **License:** GPLv2 or later **License URI:** http://www.gnu.org/licenses/gpl-2.0.html @@ -104,6 +104,12 @@ There's a known issue with WordPress `alloptions` cache design. Specifically, a ## Changelog ## +### 1.3.1 (December 2nd, 2022) ### +* Declare `wp_cache_supports` function and support features. [[#378](https://github.com/pantheon-systems/wp-redis/pull/378)] +* Make dependabot target `develop` branch for PRs. [[#376](https://github.com/pantheon-systems/wp-redis/pull/376)] + +Declare `wp_cache_supports` function and support features. [[#378](https://github.com/pantheon-systems/wp-redis/pull/378)] + ### 1.3.0 (November 29th, 2022) ### * Added CONTRIBUTING.MD and GitHub action to automate deployments to wp.org. [[#368](https://github.com/pantheon-systems/wp-redis/pull/368)] diff --git a/object-cache.php b/object-cache.php index 4f04b77..04b9948 100644 --- a/object-cache.php +++ b/object-cache.php @@ -289,6 +289,31 @@ function wp_cache_reset() { return $wp_object_cache->reset(); } +/** + * Determines whether the object cache implementation supports a particular feature. + * + * @since 6.1.0 + * + * @param string $feature Name of the feature to check for. Possible values include: + * 'add_multiple', 'set_multiple', 'get_multiple', 'delete_multiple', + * 'flush_runtime', 'flush_group'. + * @return bool True if the feature is supported, false otherwise. + */ +function wp_cache_supports( $feature ) { + switch ( $feature ) { + case 'add_multiple': + case 'set_multiple': + case 'get_multiple': + case 'delete_multiple': + case 'flush_runtime': + case 'flush_group': + return true; + + default: + return false; + } +} + /** * WordPress Object Cache * diff --git a/package-lock.json b/package-lock.json index 1bdab98..18339cd 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "wp-redis", - "version": "1.3.0", + "version": "1.3.1", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index b1c5c84..0eca0b0 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "wp-redis", - "version": "1.3.0", + "version": "1.3.1", "repository": { "type": "git", "url": "https://github.com/pantheon-systems/wp-redis.git" diff --git a/readme.txt b/readme.txt index 3feea78..4c185fa 100644 --- a/readme.txt +++ b/readme.txt @@ -2,8 +2,8 @@ Contributors: getpantheon, danielbachhuber, mboynes, Outlandish Josh Tags: cache, plugin, redis Requires at least: 3.0.1 -Tested up to: 5.9 -Stable tag: 1.3.0 +Tested up to: 6.1.1 +Stable tag: 1.3.1 License: GPLv2 or later License URI: http://www.gnu.org/licenses/gpl-2.0.html @@ -102,6 +102,10 @@ There's a known issue with WordPress `alloptions` cache design. Specifically, a == Changelog == += 1.3.1 (December 2nd, 2022) = +* Declare `wp_cache_supports` function and support features. [[#378](https://github.com/pantheon-systems/wp-redis/pull/378)] +* Make dependabot target `develop` branch for PRs. [[#376](https://github.com/pantheon-systems/wp-redis/pull/376)] + = 1.3.0 (November 29th, 2022) = * Added CONTRIBUTING.MD and GitHub action to automate deployments to wp.org. [[#368](https://github.com/pantheon-systems/wp-redis/pull/368)] diff --git a/wp-redis.php b/wp-redis.php index c374f71..a943bbd 100644 --- a/wp-redis.php +++ b/wp-redis.php @@ -3,7 +3,7 @@ * Plugin Name: WP Redis * Plugin URI: http://github.com/pantheon-systems/wp-redis/ * Description: WordPress Object Cache using Redis. Requires the PhpRedis extension (https://github.com/phpredis/phpredis). - * Version: 1.3.0 + * Version: 1.3.1 * Author: Pantheon, Josh Koenig, Matthew Boynes, Daniel Bachhuber, Alley Interactive * Author URI: https://pantheon.io/ */