Commit a934b065 authored by Erick Hitter's avatar Erick Hitter
Browse files

Support custom exception handler in configuration block of plugin

parent 74fc0525
...@@ -20,6 +20,11 @@ $GLOBALS['wp_redis_cache_config'] = array( ...@@ -20,6 +20,11 @@ $GLOBALS['wp_redis_cache_config'] = array(
// $GLOBALS['wp_redis_cache_config']['cache_duration'] = 43200; // $GLOBALS['wp_redis_cache_config']['cache_duration'] = 43200;
// $GLOBALS['wp_redis_cache_config']['unlimited'] = false; // $GLOBALS['wp_redis_cache_config']['unlimited'] = false;
// Modify this function to introduce custom handling when exceptions occur
function wp_redis_cache_exception_handler( $exception ) {
return;
}
/** /**
* DO NOT EDIT BELOW THIS LINE! * DO NOT EDIT BELOW THIS LINE!
*/ */
...@@ -172,6 +177,7 @@ try { ...@@ -172,6 +177,7 @@ try {
} }
} catch ( Exception $e ) { } catch ( Exception $e ) {
require dirname( __FILE__ ) . '/wp-blog-header.php'; require dirname( __FILE__ ) . '/wp-blog-header.php';
wp_redis_cache_exception_handler( $e );
} }
$end = microtime(); $end = microtime();
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment