Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
WP Plugins
Cron-Control
Commits
bb4ac754
Verified
Commit
bb4ac754
authored
Dec 06, 2016
by
Erick Hitter
Browse files
Review feedback: clarify that cache helper is for internal use
parent
dfac3343
Changes
2
Show whitespace changes
Inline
Side-by-side
includes/functions.php
View file @
bb4ac754
...
@@ -11,7 +11,9 @@ function is_internal_event( $action ) {
...
@@ -11,7 +11,9 @@ function is_internal_event( $action ) {
/**
/**
* Flush plugin's internal caches
* Flush plugin's internal caches
*
* FOR INTERNAL USE ONLY - see WP-CLI; all other cache clearance should happen through the `Cron_Options_CPT` class
*/
*/
function
flush_internal_caches
()
{
function
_
flush_internal_caches
()
{
return
wp_cache_delete
(
Cron_Options_CPT
::
CACHE_KEY
);
return
wp_cache_delete
(
Cron_Options_CPT
::
CACHE_KEY
);
}
}
includes/wp-cli/class-cache.php
View file @
bb4ac754
...
@@ -12,7 +12,7 @@ class Cache extends \WP_CLI_Command {
...
@@ -12,7 +12,7 @@ class Cache extends \WP_CLI_Command {
* @subcommand flush
* @subcommand flush
*/
*/
public
function
flush_internal_caches
(
$args
,
$assoc_args
)
{
public
function
flush_internal_caches
(
$args
,
$assoc_args
)
{
$flushed
=
\
Automattic\WP\Cron_Control\flush_internal_caches
();
$flushed
=
\
Automattic\WP\Cron_Control\
_
flush_internal_caches
();
if
(
$flushed
)
{
if
(
$flushed
)
{
\
WP_CLI
::
success
(
__
(
'Internal caches cleared'
,
'automattic-cron-control'
)
);
\
WP_CLI
::
success
(
__
(
'Internal caches cleared'
,
'automattic-cron-control'
)
);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment