storagesService = $storagesService; $this->numericExternalStorageId = $externalStorageId; } /** * Move the mount point to $target * * @param string $target the target mount point * @return bool */ public function moveMount($target) { $storage = $this->storagesService->getStorage($this->numericExternalStorageId); // remove "/$user/files" prefix $targetParts = explode('/', trim($target, '/'), 3); $storage->setMountPoint($targetParts[2]); $this->storagesService->updateStorage($storage); $this->setMountPoint($target); return true; } /** * Remove the mount points * * @return bool */ public function removeMount() { $this->storagesService->removeStorage($this->numericExternalStorageId); return true; } }