Upgrade/Install: Notify users of deactivated plugins during upgrade.

This adds a one-off notice to the dashboard in the event WordPress has automatically deactivated a plugin due to incompatibility with the new version of WordPress.

Introduces the new private function `deactivated_plugins_notice()` to display the notice in the dashboard. Introduces the new auto-loaded option `wp_force_deactivated_plugins` to store a list of automatically deactivated plugins; the option is used on both a site and network level.

Follow up to [51180].

Props desrosj, jorbin, azaozz, SergeyBiryukov, peterwilsoncc.
See #53432.



git-svn-id: https://develop.svn.wordpress.org/trunk@51266 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Peter Wilson
2021-06-30 00:20:52 +00:00
parent 41164a2eaa
commit 2a02de7d53
4 changed files with 103 additions and 0 deletions

View File

@@ -542,6 +542,9 @@ function populate_options( array $options = array() ) {
// Default to enabled for new installs.
// See https://core.trac.wordpress.org/ticket/51742.
'auto_update_core_major' => 'enabled',
// 5.8.0
'wp_force_deactivated_plugins' => array(),
);
// 3.3.0