diff options
author | Thomas Müller <thomas.mueller@tmit.eu> | 2015-09-23 11:34:23 +0200 |
---|---|---|
committer | Thomas Müller <thomas.mueller@tmit.eu> | 2015-09-23 11:34:23 +0200 |
commit | bcdb3c26da28e3797833da3afaac997d067730be (patch) | |
tree | e57c43b6b2c5bf1340599be36f257f9f8be99cfb /lib/private/files/storage/common.php | |
parent | 4c62d71db7f1b8ff490011bcc5050e835b70e745 (diff) | |
parent | 491250320a6b19f9a7d546598e97eac1e90f78f7 (diff) | |
download | nextcloud-server-bcdb3c26da28e3797833da3afaac997d067730be.tar.gz nextcloud-server-bcdb3c26da28e3797833da3afaac997d067730be.zip |
Merge pull request #19236 from owncloud/call_dot_directories_function
Replaces if ($file === '.' || $file === '..') by public function call isIgnoredDir
Diffstat (limited to 'lib/private/files/storage/common.php')
-rw-r--r-- | lib/private/files/storage/common.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/private/files/storage/common.php b/lib/private/files/storage/common.php index a5ed5fd3996..2d579fa2b60 100644 --- a/lib/private/files/storage/common.php +++ b/lib/private/files/storage/common.php @@ -260,7 +260,7 @@ abstract class Common implements Storage { $dh = $this->opendir($path); if (is_resource($dh)) { while (($file = readdir($dh)) !== false) { - if ($file !== '.' and $file !== '..') { + if (!\OC\Files\Filesystem::isIgnoredDir($file)) { if ($this->is_dir($path . '/' . $file)) { mkdir($target . '/' . $file); $this->addLocalFolder($path . '/' . $file, $target . '/' . $file); @@ -283,7 +283,7 @@ abstract class Common implements Storage { $dh = $this->opendir($dir); if (is_resource($dh)) { while (($item = readdir($dh)) !== false) { - if ($item == '.' || $item == '..') continue; + if (\OC\Files\Filesystem::isIgnoredDir($item)) continue; if (strstr(strtolower($item), strtolower($query)) !== false) { $files[] = $dir . '/' . $item; } |