diff options
author | patdenice <patdenice@piwigo.org> | 2011-11-17 18:09:37 +0000 |
---|---|---|
committer | patdenice <patdenice@piwigo.org> | 2011-11-17 18:09:37 +0000 |
commit | 95325c68cfd80e5203de0f5dcd975aecd49445b8 (patch) | |
tree | 045cb2b15c69bd888a2af109d552f7b8022b8cf9 /admin | |
parent | 5c7f267455fc1b6711b03d8b30082d8615f1793e (diff) |
bug:2513
Warning messages during synchronisation on some servers
git-svn-id: http://piwigo.org/svn/trunk@12642 68402e56-0260-453c-a942-63ccdbb3a9ee
Diffstat (limited to 'admin')
-rw-r--r-- | admin/include/functions.php | 6 | ||||
-rw-r--r-- | admin/site_reader_local.php | 4 |
2 files changed, 5 insertions, 5 deletions
diff --git a/admin/include/functions.php b/admin/include/functions.php index 77e419d5b..dfc596235 100644 --- a/admin/include/functions.php +++ b/admin/include/functions.php @@ -533,13 +533,13 @@ function get_fs_directories($path, $recursive = true) { while (($node = readdir($contents)) !== false) { - if (is_dir($path.'/'.$node) - and $node != '.' + if ($node != '.' and $node != '..' and $node != '.svn' and $node != 'thumbnail' and $node != 'pwg_high' - and $node != 'pwg_representative') + and $node != 'pwg_representative' + and is_dir($path.'/'.$node)) { array_push($dirs, $path.'/'.$node); if ($recursive) diff --git a/admin/site_reader_local.php b/admin/site_reader_local.php index da12e9398..5a48fe30a 100644 --- a/admin/site_reader_local.php +++ b/admin/site_reader_local.php @@ -84,6 +84,8 @@ function get_elements($path) { while (($node = readdir($contents)) !== false) { + if ($node == '.' or $node == '..') continue; + if (is_file($path.'/'.$node)) { $extension = get_extension($node); @@ -98,8 +100,6 @@ function get_elements($path) } } elseif (is_dir($path.'/'.$node) - and $node != '.' - and $node != '..' and $node != 'pwg_high' and $node != 'pwg_representative' and $node != 'thumbnail' ) |