Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 14 additions & 1 deletion src/wp-admin/includes/plugin.php
Original file line number Diff line number Diff line change
Expand Up @@ -1247,7 +1247,20 @@ function validate_plugin_requirements( $plugin ) {
);
}

return true;
/**
* Filters the plugin requirement validation response.
*
* If a plugin fails due to a Core-provided validation (incompatible WP, PHP versions), this
* filter will not fire. A WP_Error response will already be returned.
*
* This filter is intended to add additional validation steps by site administrators.
*
* @since 6.9.0
*
* @param bool|WP_Error $met_requirements True if the plugin meets requirements, WP_Error if not.
* @param string $plugin Path to the plugin file relative to the plugins directory.
*/
return apply_filters( 'validate_plugin_requirements', true, $plugin );
}

/**
Expand Down
Loading