diff --git a/plugins/FeedsFileFetcher.inc b/plugins/FeedsFileFetcher.inc index 3d7d5fb64c55e19d84f2c0c1da27ae3080f070f0..7e1f961a4f8525a78dd445ce965259ef45299eca 100644 --- a/plugins/FeedsFileFetcher.inc +++ b/plugins/FeedsFileFetcher.inc @@ -82,7 +82,7 @@ class FeedsFileFetcher extends FeedsFetcher { protected function listFiles($dir) { $dir = file_stream_wrapper_uri_normalize($dir); $files = array(); - if ($items = scandir($dir)) { + if ($items = @scandir($dir)) { foreach ($items as $item) { if (is_file("$dir/$item") && strpos($item, '.') !== 0) { $files[] = "$dir/$item"; diff --git a/tests/feeds.test.inc b/tests/feeds.test.inc index 7ea79f20d02ff398eee079f5b42049f809c7f099..b8efbe67c627e559c74ff1751e244728cf7119a2 100644 --- a/tests/feeds.test.inc +++ b/tests/feeds.test.inc @@ -415,7 +415,7 @@ class FeedsWebTestCase extends DrupalWebTestCase { */ public function copyDir($source, $dest) { $result = file_prepare_directory($dest, FILE_CREATE_DIRECTORY | FILE_MODIFY_PERMISSIONS); - foreach (scandir($source) as $file) { + foreach (@scandir($source) as $file) { if (is_file("$source/$file")) { $file = file_unmanaged_copy("$source/$file", "$dest/$file"); }