summaryrefslogtreecommitdiff
path: root/fs/multifs.py
diff options
context:
space:
mode:
authorwillmcgugan <willmcgugan@67cdc799-7952-0410-af00-57a81ceafa0f>2012-01-11 23:20:40 +0000
committerwillmcgugan <willmcgugan@67cdc799-7952-0410-af00-57a81ceafa0f>2012-01-11 23:20:40 +0000
commit60da3d535a5d591b7003e93e66364bd6ea161461 (patch)
tree004a11f32f97d350eeade38c97cb933c4c08d282 /fs/multifs.py
parentdb293aaba268dff6cd9085be9adfc9f0c90ef8aa (diff)
downloadpyfilesystem-git-60da3d535a5d591b7003e93e66364bd6ea161461.tar.gz
Fixed copydir/movedir, added DeleteRootError
Diffstat (limited to 'fs/multifs.py')
-rw-r--r--fs/multifs.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/fs/multifs.py b/fs/multifs.py
index f960dd6..cd4e987 100644
--- a/fs/multifs.py
+++ b/fs/multifs.py
@@ -292,7 +292,9 @@ class MultiFS(FS):
@synchronize
def removedir(self, path, recursive=False, force=False):
if self.writefs is None:
- raise OperationFailedError('removedir', path=path, msg="No writeable FS set")
+ raise OperationFailedError('removedir', path=path, msg="No writeable FS set")
+ if normpath(path) in ('', '/'):
+ raise DeleteRootError(path)
self.writefs.removedir(path, recursive=recursive, force=force)
@synchronize