Added HTTP code 302 (Found) to expected codes when invoking mkdir with

safe=True.
master
amnong 2012-06-17 17:20:52 +03:00
parent f542721024
commit 803c9884fb
1 changed files with 1 additions and 1 deletions

View File

@ -64,7 +64,7 @@ class Client(object):
else:
self.cwd += stripped_path
def mkdir(self, path, safe=False):
expected_codes = 201 if not safe else (201, 301)
expected_codes = 201 if not safe else (201, 301, 302)
self._send('MKCOL', path, expected_codes)
def mkdirs(self, path):
dirs = [d for d in path.split('/') if d]