mirror of
https://github.com/samsonjs/vdirsyncer.git
synced 2026-03-25 08:55:50 +00:00
Fix deprecation warning
This commit is contained in:
parent
e5bc3fd6e7
commit
a217623e8e
1 changed files with 2 additions and 2 deletions
|
|
@ -201,7 +201,7 @@ class Discover(object):
|
|||
props = _merge_xml(response.findall(
|
||||
'{DAV:}propstat/{DAV:}prop'
|
||||
))
|
||||
if not props:
|
||||
if props is None or not len(props):
|
||||
dav_logger.debug('Skipping, missing <prop>: %s', response)
|
||||
return False
|
||||
if props.find('{DAV:}resourcetype/' + self._resourcetype) \
|
||||
|
|
@ -561,7 +561,7 @@ class DAVStorage(Storage):
|
|||
continue
|
||||
|
||||
props = response.findall('{DAV:}propstat/{DAV:}prop')
|
||||
if not props:
|
||||
if props is None or not len(props):
|
||||
dav_logger.warning('Skipping {!r}, properties are missing.'
|
||||
.format(href))
|
||||
continue
|
||||
|
|
|
|||
Loading…
Reference in a new issue