wp-autoupdates
wp-autoupdates copied to clipboard
Documentation
Migrated from: https://github.com/audrasjb/wp-autoupdates/issues/71 Previously opened by: @jeffpaul Original description:
We'll want to ensure that ahead of any submission to merge this plugin into WordPress core that we've sufficiently documented within the plugin code and within the markdown/text files in this plugin. Assuming there is a feature plugin merge proposal for this plugin, we'll want to ensure we capture items that should be included in the WordPress Core HelpHub documentation site as well.
I'll add separate comments below for the constants and hooks that control various aspects of functionality.
~~These are the constants used by this plugin that are not already in core:~~
- ~~WP_DISABLE_PLUGINS_AUTO_UPDATE~~
- ~~WP_DISABLE_THEMES_AUTO_UPDATE~~
- ~~WP_DISABLE_PLUGINS_AUTO_UPDATE_EMAIL~~
- ~~WP_DISABLE_THEMES_AUTO_UPDATE_EMAIL~~
~~Like the existing AUTOMATIC_UPDATER_DISABLED constant, the merge proposal will not define these constants, but site owners (or other plugins) may define them. If they are defined and true, then the auto-update UI for their respective extension type will not display.~~
On 2020-05-05 it was decided to remove all the constants. That decision was implemented in #112 and is now part of Version 0.7.0.
These are the filters defined by this plugin (and will be part of the merge proposal):
- wp_plugins_auto_update_enabled
- wp_themes_auto_update_enabled
- wp_autoupdates_notifications_email
- send_plugins_auto_update_email
- send_themes_auto_update_email
All have complete DocBlocks (except for the @since tag, which I think is OK).
I suspect that the name of wp_autoupdates_notifications_email will change as part of the merge proposal.
It is a bit off topic but there are two constants DISALLOW_FILE_EDIT and DISALLOW_FILE_MODS https://wordpress.org/support/article/editing-wp-config-php/#disable-the-plugin-and-theme-editor
They are not related directly to UPDATE functions but there is conflict for example if WP_AUTO_UPDATE_CORE = true and DISALLOW_FILE_MODS = true. Which of the constants should take precedence?
I think it should be documented at least.
I am hoping that there will be a toggle/or some other switch to turn off email notification. Perhaps add a control to one of the WP Settings pages.
With the existing constants being removed will there be any new constants or filters to be able to disable automatic plugin or theme updates from showing in the UI? https://github.com/WordPress/wp-autoupdates/pull/112
No new constants and no additional filters, but
- wp_plugins_auto_update_enabled
- wp_themes_auto_update_enabled
still exist.
e.g. add_filter( 'wp_plugins_auto_update_enabled', '__return_false' ) will disable the UI on the plugins screen.
@pbiron
Thank you.
add_filter( 'wp_plugins_auto_update_enabled', '__return_false' );
add_filter( 'wp_themes_auto_update_enabled', '__return_false' );
Those filters do not disable either of the plugins or themes UI from showing does not seem to work correctly when testing on the nightly build (5.5-alpha-48271) of WordPress.


Thanx for the reminder. As part of the core merge, those filters were renamed to:
plugins_auto_update_enabledthemes_auto_update_enabled
they still have the same names in the latest version of this feature plugin.
@pbiron Thanks for the info.