summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/bookmark.py12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/bookmark.py b/src/bookmark.py
index 67ef5eba..019452eb 100644
--- a/src/bookmark.py
+++ b/src/bookmark.py
@@ -92,6 +92,18 @@ def remove(value):
value = get_by_jid(value)
bookmarks.remove(value)
+def stanza_pep():
+ storage = Storage()
+ for b in filter(lambda b: b.method == 'pep', bookmarks):
+ storage.append(b.stanza())
+ return storage
+
+def stanza_privatexml():
+ storage = Storage()
+ for b in filter(lambda b: b.method == 'privatexml', bookmarks):
+ storage.append(b.stanza())
+ return storage
+
def save_pep(xmpp):
xmpp.plugin['xep_0048'].set_bookmarks(stanza_pep())