mirror of
https://github.com/samsonjs/vdirsyncer.git
synced 2026-04-05 10:45:51 +00:00
DAV: Remove warning about missing etag on PUT
This commit is contained in:
parent
7f705aeb3a
commit
4b0a896303
1 changed files with 6 additions and 4 deletions
|
|
@ -445,11 +445,13 @@ class DavStorage(Storage):
|
|||
etag = response.headers.get('etag', None)
|
||||
href = self._normalize_href(response.url)
|
||||
if not etag:
|
||||
dav_logger.warning('Race condition detected with server {}, '
|
||||
'consider using an alternative.'
|
||||
.format(self.session.parsed_url.netloc))
|
||||
# The server violated the RFC and didn't send an etag.
|
||||
# ownCloud: https://github.com/owncloud/contacts/issues/920
|
||||
dav_logger.debug('Server did not send etag, fetching {!r}'
|
||||
.format(href))
|
||||
item2, etag = self.get(href)
|
||||
assert item2.uid == item.uid
|
||||
if item2.raw != item.raw:
|
||||
raise exceptions.WrongEtagError(href)
|
||||
return href, etag
|
||||
|
||||
def update(self, href, item, etag):
|
||||
|
|
|
|||
Loading…
Reference in a new issue