prove some compatibility with the old cache api

This commit is contained in:
Robin Appelman 2012-10-26 23:25:52 +02:00
parent 6db81afab9
commit 7d6da68d53

View file

@ -712,7 +712,7 @@ class View {
$files = $cache->getFolderContents($internalPath); //TODO: mimetype_filter
//add a folder for any mountpoint in this directory and add the sizes of other mountpoints to the folders
$mountPoints = Filesystem::getMountPoints($directory);
$mountPoints = Filesystem::getMountPoints($path);
$dirLength = strlen($path);
foreach ($mountPoints as $mountPoint) {
$subStorage = Filesystem::getStorage($mountPoint);
@ -733,6 +733,10 @@ class View {
}
}
foreach($files as $i => $file){
$files[$i]['type'] = $file['mimetype'] === 'httpd/unix-directory' ? 'dir' : 'file';
}
usort($files, "fileCmp"); //TODO: remove this once ajax is merged
return $files;
}