plugins_update_check_locales

plugins_update_check_locales

Appears in: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
Hook Type: filter

See hook in core

Displaying hooks found in version: wordpress-6.7

apply_filters('plugins_update_check_locales') is found 2 times:

  • /wp-includes/rest-api/endpoints/class-wp-rest-plugins-controller.php line 381
     
    		// Install translations.
    		$installed_locales = array_values( get_available_languages() );
    		/** This filter is documented in wp-includes/update.php */
    		$installed_locales = apply_filters( 'plugins_update_check_locales', $installed_locales );
    
    		$language_packs = array_map(
    			static function ( $item ) {
    				return (object) $item;
    			},
    			$api->language_packs
    
  • /wp-includes/update.php line 407
    	 * @since 4.5.0 The default value of the `$locales` parameter changed to include all locales.
    	 *
    	 * @param string[] $locales Plugin locales. Default is all available locales of the site.
    	 */
    	$locales = apply_filters( 'plugins_update_check_locales', $locales );
    	$locales = array_unique( $locales );
    
    	if ( $doing_cron ) {
    		$timeout = 30; // 30 seconds.
    	} else {
    		// Three seconds, plus one extra second for every 10 plugins.