We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
function_exists
1 parent 06379c6 commit 168d562Copy full SHA for 168d562
1 file changed
src/WP_CLI/CommandWithTranslation.php
@@ -443,13 +443,12 @@ protected function get_formatter( &$assoc_args ) {
443
/**
444
* Clears the translation files cache for a given directory.
445
*
446
+ * As of WP 6.5, the presence of .mo and .l10n.php files is cached.
447
+ *
448
* @param string $dir The directory to clear the cache for.
449
*/
450
protected function clear_translation_files_cache( $dir ) {
- // As of WP 6.5, the presence of .mo and .l10n.php files is cached.
- if ( function_exists( 'wp_cache_delete' ) ) {
451
- $path = rtrim( $dir, '/' ) . '/';
452
- wp_cache_delete( md5( $path ), 'translation_files' );
453
- }
+ $path = rtrim( $dir, '/' ) . '/';
+ wp_cache_delete( md5( $path ), 'translation_files' );
454
}
455
0 commit comments