Skip to content

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
richardkorthuis committed Mar 7, 2024
2 parents 1788498 + 689887c commit 75c6e4a
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 4 deletions.
5 changes: 4 additions & 1 deletion admin/includes/class-api-caches-table.php
Original file line number Diff line number Diff line change
Expand Up @@ -318,7 +318,7 @@ public function process_action() {
*/
private function process_single_action( $action ) {
if ( ! isset( $_GET['wp_rest_cache_nonce'] ) || ! wp_verify_nonce( sanitize_key( $_GET['wp_rest_cache_nonce'] ), 'wp_rest_cache_' . $action . '_cache' ) ) {
die( 'No naughty business please' );
return;
}
$cache_key = filter_input( INPUT_GET, 'cache_key', FILTER_SANITIZE_FULL_SPECIAL_CHARS );
self::clear_cache( $cache_key, ( 'delete' === $action ) );
Expand All @@ -334,6 +334,9 @@ private function process_single_action( $action ) {
* @return void
*/
private function process_bulk_action( $action ) {
if ( ! isset( $_GET['_wpnonce'] ) || ! wp_verify_nonce( sanitize_key( $_GET['_wpnonce'] ), 'bulk-' . sanitize_key( __( 'Endpoint API Caches', 'wp-rest-cache' ) ) ) ) {
return;
}
$caches = filter_input( INPUT_GET, 'bulk-flush', FILTER_SANITIZE_FULL_SPECIAL_CHARS, FILTER_REQUIRE_ARRAY );
foreach ( $caches as $cache_key ) {
self::clear_cache( $cache_key, ( 'bulk-delete' === $action ) );
Expand Down
2 changes: 1 addition & 1 deletion includes/class-plugin.php
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ class Plugin {
*/
public function __construct() {
$this->plugin_name = 'wp-rest-cache';
$this->version = '2024.1.1';
$this->version = '2024.1.2';

$this->set_locale();
$this->define_admin_hooks();
Expand Down
7 changes: 6 additions & 1 deletion readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Tags: cache, wp-rest-api, api, rest, rest cache
Requires at least: 4.7
Tested up to: 6.5
Requires PHP: 7.0
Stable tag: 2024.1.1
Stable tag: 2024.1.2
License: GPLv3
License URI: http://www.gnu.org/licenses/gpl.html

Expand Down Expand Up @@ -171,6 +171,11 @@ Yes you can! Use the `wp wp-rest-cache flush` command to flush caches. Type `wp

== Changelog ==

= 2024.1.2 =
Release Date: March 7th, 2024

Bugfix: Fix where the plugin caused an error on permanently deleting items.

= 2024.1.1 =
Release Date: March 6th, 2024

Expand Down
2 changes: 1 addition & 1 deletion wp-rest-cache.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
* Plugin Name: WP REST Cache
* Plugin URI: https://www.acato.nl
* Description: Adds caching to the WP REST API
* Version: 2024.1.1
* Version: 2024.1.2
* Author: Acato
* Author URI: https://www.acato.nl
* Text Domain: wp-rest-cache
Expand Down

0 comments on commit 75c6e4a

Please sign in to comment.