mirror of
https://github.com/samsonjs/vdirsyncer.git
synced 2026-04-27 14:57:41 +00:00
Skip non-directories during filesystem discovery
This commit is contained in:
parent
11919ef30d
commit
29f9a10766
1 changed files with 3 additions and 2 deletions
|
|
@ -54,6 +54,7 @@ class FilesystemStorage(Storage):
|
||||||
raise TypeError('collection argument must not be given.')
|
raise TypeError('collection argument must not be given.')
|
||||||
path = expand_path(path)
|
path = expand_path(path)
|
||||||
for collection in os.listdir(path):
|
for collection in os.listdir(path):
|
||||||
|
if os.path.isdir(os.path.join(path, collection)):
|
||||||
s = cls(path=path, collection=collection, **kwargs)
|
s = cls(path=path, collection=collection, **kwargs)
|
||||||
yield s
|
yield s
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue