Checks whether auto-updates are forced for an item.
Parameters
$type
stringrequired- The type of update being checked: Either
'theme'
or'plugin'
. $update
bool|nullrequired- Whether to update. The value of null is internally used to detect whether nothing has hooked into this filter.
$item
objectrequired- The update offer.
Source
function wp_is_auto_update_forced_for_item( $type, $update, $item ) {
/** This filter is documented in wp-admin/includes/class-wp-automatic-updater.php */
return apply_filters( "auto_update_{$type}", $update, $item );
}
Hooks
- apply_filters( “auto_update_{$type}”,
bool|null $update ,object $item ) Filters whether to automatically update core, a plugin, a theme, or a language.
Changelog
Version | Description |
---|---|
5.6.0 | Introduced. |
User Contributed Notes
You must log in before being able to contribute a note or feedback.