@@ -28,36 +28,36 @@ |
||
| 28 | 28 | |
| 29 | 29 | class FilesHome extends Directory { |
| 30 | 30 | |
| 31 | - /** |
|
| 32 | - * @var array |
|
| 33 | - */ |
|
| 34 | - private $principalInfo; |
|
| 31 | + /** |
|
| 32 | + * @var array |
|
| 33 | + */ |
|
| 34 | + private $principalInfo; |
|
| 35 | 35 | |
| 36 | - /** |
|
| 37 | - * FilesHome constructor. |
|
| 38 | - * |
|
| 39 | - * @param array $principalInfo |
|
| 40 | - */ |
|
| 41 | - public function __construct($principalInfo) { |
|
| 42 | - $this->principalInfo = $principalInfo; |
|
| 43 | - $view = \OC\Files\Filesystem::getView(); |
|
| 44 | - $rootInfo = $view->getFileInfo(''); |
|
| 45 | - if (!($rootInfo instanceof FileInfo)) { |
|
| 46 | - throw new \Exception('Home does not exist'); |
|
| 47 | - } |
|
| 48 | - parent::__construct($view, $rootInfo); |
|
| 49 | - } |
|
| 36 | + /** |
|
| 37 | + * FilesHome constructor. |
|
| 38 | + * |
|
| 39 | + * @param array $principalInfo |
|
| 40 | + */ |
|
| 41 | + public function __construct($principalInfo) { |
|
| 42 | + $this->principalInfo = $principalInfo; |
|
| 43 | + $view = \OC\Files\Filesystem::getView(); |
|
| 44 | + $rootInfo = $view->getFileInfo(''); |
|
| 45 | + if (!($rootInfo instanceof FileInfo)) { |
|
| 46 | + throw new \Exception('Home does not exist'); |
|
| 47 | + } |
|
| 48 | + parent::__construct($view, $rootInfo); |
|
| 49 | + } |
|
| 50 | 50 | |
| 51 | - function delete() { |
|
| 52 | - throw new Forbidden('Permission denied to delete home folder'); |
|
| 53 | - } |
|
| 51 | + function delete() { |
|
| 52 | + throw new Forbidden('Permission denied to delete home folder'); |
|
| 53 | + } |
|
| 54 | 54 | |
| 55 | - function getName() { |
|
| 56 | - list(,$name) = URLUtil::splitPath($this->principalInfo['uri']); |
|
| 57 | - return $name; |
|
| 58 | - } |
|
| 55 | + function getName() { |
|
| 56 | + list(,$name) = URLUtil::splitPath($this->principalInfo['uri']); |
|
| 57 | + return $name; |
|
| 58 | + } |
|
| 59 | 59 | |
| 60 | - function setName($name) { |
|
| 61 | - throw new Forbidden('Permission denied to rename this folder'); |
|
| 62 | - } |
|
| 60 | + function setName($name) { |
|
| 61 | + throw new Forbidden('Permission denied to rename this folder'); |
|
| 62 | + } |
|
| 63 | 63 | } |