diff --git a/feeds.module b/feeds.module index 3798eac..cf6ca12 100644 --- a/feeds.module +++ b/feeds.module @@ -966,15 +966,9 @@ function feeds_plugin($plugin, $id) { */ function feeds_include_library($file, $library) { static $included = array(); - static $ignore_deprecated = array('simplepie'); if (!isset($included[$file])) { - // Disable deprecated warning for libraries known for throwing them - if (in_array($library, $ignore_deprecated)) { - $level = error_reporting(); - // We can safely use E_DEPRECATED since Drupal 7 requires PHP 5.3+ - error_reporting($level ^ E_DEPRECATED ^ E_STRICT); - } + $included[$file] = FALSE; $library_dir = variable_get('feeds_library_dir', FALSE); $feeds_library_path = DRUPAL_ROOT . '/' . drupal_get_path('module', 'feeds') . "/libraries/$file"; @@ -995,15 +989,9 @@ function feeds_include_library($file, $library) { require $feeds_library_path; $included[$file] = TRUE; } - // Restore error reporting level - if (isset($level)) { - error_reporting($level); - } - } - if (isset($included[$file])) { - return TRUE; } - return FALSE; + + return $included[$file]; } /** diff --git a/plugins/FeedsSimplePieParser.inc b/plugins/FeedsSimplePieParser.inc index cadb6b8..f87d913 100644 --- a/plugins/FeedsSimplePieParser.inc +++ b/plugins/FeedsSimplePieParser.inc @@ -67,10 +67,6 @@ class FeedsSimplePieParser extends FeedsParser { public function parse(FeedsSource $source, FeedsFetcherResult $fetcher_result) { feeds_include_simplepie(); - // Please be quiet SimplePie. - $level = error_reporting(); - error_reporting($level ^ E_DEPRECATED ^ E_STRICT); - // Initialize SimplePie. $parser = new SimplePie(); $parser->set_raw_data($fetcher_result->getRaw()); @@ -149,8 +145,7 @@ class FeedsSimplePieParser extends FeedsParser { } // Release parser. unset($parser); - // Set error reporting back to its previous value. - error_reporting($level); + return $result; }