Changes in trunk/wp-includes/class-feed.php [11787:17928]
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/class-feed.php
r11787 r17928 5 5 6 6 class WP_Feed_Cache extends SimplePie_Cache { 7 /**8 * Don't call the constructor. Please.9 *10 * @access private11 */12 function WP_Feed_Cache() {13 trigger_error('Please call SimplePie_Cache::create() instead of the constructor', E_USER_ERROR);14 }15 16 7 /** 17 8 * Create a new SimplePie_Cache object … … 30 21 var $lifetime = 43200; //Default lifetime in cache of 12 hours 31 22 32 function WP_Feed_Cache_Transient($location, $filename, $extension) {23 function __construct($location, $filename, $extension) { 33 24 $this->name = 'feed_' . $filename; 34 25 $this->mod_name = 'feed_mod_' . $filename; … … 66 57 class WP_SimplePie_File extends SimplePie_File { 67 58 68 function WP_SimplePie_File($url, $timeout = 10, $redirects = 5, $headers = null, $useragent = null, $force_fsockopen = false) {59 function __construct($url, $timeout = 10, $redirects = 5, $headers = null, $useragent = null, $force_fsockopen = false) { 69 60 $this->url = $url; 70 61 $this->timeout = $timeout; … … 90 81 $this->success = false; 91 82 } else { 92 $this->headers = $res['headers'];93 $this->body = $res['body'];94 $this->status_code = $res['response']['code'];83 $this->headers = wp_remote_retrieve_headers( $res ); 84 $this->body = wp_remote_retrieve_body( $res ); 85 $this->status_code = wp_remote_retrieve_response_code( $res ); 95 86 } 96 87 } else {
Note: See TracChangeset
for help on using the changeset viewer.