wp-includes/class-wp-textdomain-registry.php:252Invalidate the cache for .mo files.
$upgraderWP_Upgrader$hook_extraarray$actionstringdefault: 'update'
$typestring
$bulkbooldefault: true
$pluginsarray
$themesarray
$translationsarray
$languagestring
$typestring
$slugstring
$versionstring
public function invalidate_mo_files_cache( $upgrader, $hook_extra ) { if ( ! isset( $hook_extra['type'] ) || 'translation' !== $hook_extra['type'] || array() === $hook_extra['translations'] ) { return; } $translation_types = array_unique( wp_list_pluck( $hook_extra['translations'], 'type' ) ); foreach ( $translation_types as $type ) { switch ( $type ) { case 'plugin': wp_cache_delete( md5( WP_LANG_DIR . '/plugins/' ), 'translation_files' ); break; case 'theme': wp_cache_delete( md5( WP_LANG_DIR . '/themes/' ), 'translation_files' ); break; default: wp_cache_delete( md5( WP_LANG_DIR . '/' ), 'translation_files' ); break; } } }Introduced in 6.5.0. Unchanged from 6.7.7 through 7.1.0.
Signature, return type and hooks compared across 5 parsed releases.
src/wp-includes/class-wp-textdomain-registry.php, and regenerated for each WordPress release so it tracks the code rather than a snapshot of it.