Adds checking for fsockopen to check for WP_DEBUG and silently drop warnings. Adds streams_set_timeout to fsockopen to help prevent long waits. Props santosj. see #7514

git-svn-id: https://develop.svn.wordpress.org/trunk@8644 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Ryan Boren
2008-08-13 23:37:42 +00:00
parent 21400530e1
commit 93f3f4cdb5
2 changed files with 16 additions and 3 deletions

View File

@@ -145,6 +145,9 @@ function wp_update_plugins() {
$raw_response = wp_remote_request('http://api.wordpress.org/plugins/update-check/1.0/', $options);
if ( is_wp_error( $raw_response ) )
return false;
if( 200 != $raw_response['response']['code'] ) {
return false;
}