wp_cron_conditionally_prevent_sslverify()
Disables SSL verification if the cron_request include an HTTPS URL.
This prevents an issue if HTTPS breaks, where there would be a failed attempt to verify HTTPS.
No Hooks.
Return
Array
. The filtered Cron request arguments.
Usage
wp_cron_conditionally_prevent_sslverify( $request );
- $request(array) (required)
- The Cron request arguments.
Changelog
Since 5.7.0 | Introduced. |
Code of wp_cron_conditionally_prevent_sslverify() wp cron conditionally prevent sslverify WP 6.0
function wp_cron_conditionally_prevent_sslverify( $request ) { if ( 'https' === wp_parse_url( $request['url'], PHP_URL_SCHEME ) ) { $request['args']['sslverify'] = false; } return $request; }