Fix bookmarks strategy
Strategy is now: 1. Get pubsub if supported 2. Get private storage and merge if we find boomarks we dont have 3. Store bookmarks to both pubsub and privatestorage The only drawback with this strategy is, that a client that supports only private storage cant delete bookmarks
This commit is contained in:
parent
c3a359ba23
commit
4cb852914e
|
@ -160,7 +160,8 @@ class Bookmarks:
|
|||
continue
|
||||
|
||||
if check_merge:
|
||||
if jid not in self.bookmarks:
|
||||
if jid in self.bookmarks:
|
||||
continue
|
||||
merged = True
|
||||
|
||||
log.debug('Found Bookmark: %s', jid)
|
||||
|
@ -218,7 +219,6 @@ class Bookmarks:
|
|||
if storage_type is None:
|
||||
if self._pubsub_support():
|
||||
self._pubsub_store(storage_node)
|
||||
else:
|
||||
self._private_store(storage_node)
|
||||
elif storage_type == BookmarkStorageType.PUBSUB:
|
||||
if self._pubsub_support():
|
||||
|
|
Loading…
Reference in New Issue