aboutsummaryrefslogtreecommitdiffstats
path: root/lib/files/view.php
diff options
context:
space:
mode:
Diffstat (limited to 'lib/files/view.php')
-rw-r--r--lib/files/view.php16
1 files changed, 16 insertions, 0 deletions
diff --git a/lib/files/view.php b/lib/files/view.php
index 302232b5134..dfcb770328b 100644
--- a/lib/files/view.php
+++ b/lib/files/view.php
@@ -670,6 +670,9 @@ class View {
*/
public function getFileInfo($path) {
$data = array();
+ if (!Filesystem::isValidPath($path)) {
+ return $data;
+ }
$path = Filesystem::normalizePath($this->fakeRoot . '/' . $path);
/**
* @var \OC\Files\Storage\Storage $storage
@@ -724,6 +727,9 @@ class View {
*/
public function getDirectoryContent($directory, $mimetype_filter = '') {
$result = array();
+ if (!Filesystem::isValidPath($directory)) {
+ return $result;
+ }
$path = Filesystem::normalizePath($this->fakeRoot . '/' . $directory);
/**
* @var \OC\Files\Storage\Storage $storage
@@ -915,6 +921,16 @@ class View {
}
/**
+ * Get the owner for a file or folder
+ *
+ * @param string $path
+ * @return string
+ */
+ public function getOwner($path) {
+ return $this->basicOperation('getOwner', $path);
+ }
+
+ /**
* get the ETag for a file or folder
*
* @param string $path