fileserver.s3fs: avoid shadowing dir() built-in

This commit is contained in:
Chris Rebert 2014-10-20 10:09:53 -07:00
parent 3cf0cfb61d
commit 20de52366c

View File

@ -500,9 +500,9 @@ def _find_dirs(metadata):
for path in [k['Key'] for k in data]:
prefix = ''
for part in path.split('/')[:-1]:
dir = prefix + part + '/'
ret[bucket_name].add(dir)
prefix = dir
directory = prefix + part + '/'
ret[bucket_name].add(directory)
prefix = directory
return ret