Make WordPress Core

Changes between Version 1 and Version 2 of Ticket #60457, comment 7


Ignore:
Timestamp:
02/07/2024 01:01:04 PM (2 years ago)
Author:
costdev
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #60457, comment 7

    v1 v2  
    44
    55- Proposal: Remove the part of the dependencies check in the `wp_get_active_and_valid_plugins()` loop that deals with plugins that require other plugins.
     6- Supplementary proposal: Guard the call to `WP_Plugin_Dependencies::deactivate_dependents_with_unmet_dependencies()` so it only runs on the admin's `plugins.php` page.
    67
    78`WP_Plugin_Dependencies::initialize()` runs during bootstrap, before the `wp_get_active_and_valid_plugins()` loop. This means that `WP_Plugin_Dependencies::deactivate_dependents_with_unmet_dependencies()` will have already deactivated said plugins if necessary, and therefore the `wp_get_active_and_valid_plugins()` loop won't deal with plugins that require other plugins. There's no need to have that part of the logic included in the loop and therefore running twice.