Skip to content

Commit 146a8ca

Browse files
Copilotswissspidy
andauthored
Remove redundant function_exists check for wp_cache_flush
Agent-Logs-Url: https://github.com/wp-cli/search-replace-command/sessions/1512ccf8-036b-4e5b-9306-3307f06eae27 Co-authored-by: swissspidy <841956+swissspidy@users.noreply.github.com>
1 parent 9abe70a commit 146a8ca

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/Search_Replace_Command.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -616,7 +616,7 @@ public function __invoke( $args, $assoc_args ) {
616616
if ( ! empty( $assoc_args['export'] ) ) {
617617
$success_message = 1 === $total ? "Made 1 replacement and exported to {$assoc_args['export']}." : "Made {$total} replacements and exported to {$assoc_args['export']}.";
618618
} else {
619-
if ( $total && 'Default' !== Utils\wp_get_cache_type() && function_exists( 'wp_cache_flush' ) ) {
619+
if ( $total && 'Default' !== Utils\wp_get_cache_type() ) {
620620
wp_cache_flush();
621621
}
622622

0 commit comments

Comments
 (0)