Changeset

4844:cc17708ba777

mod_bookmarks2: Remove wrong codepath (thanks luacheck!)
author Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
date Tue, 04 Jan 2022 22:57:06 +0100
parents 4843:60887967b797
children 4845:6e17df6becec
files mod_bookmarks2/mod_bookmarks2.lua
diffstat 1 files changed, 2 insertions(+), 7 deletions(-) [+]
line wrap: on
line diff
--- a/mod_bookmarks2/mod_bookmarks2.lua	Tue Jan 04 20:21:10 2022 +0100
+++ b/mod_bookmarks2/mod_bookmarks2.lua	Tue Jan 04 22:57:06 2022 +0100
@@ -122,13 +122,8 @@
 	local service = mod_pep.get_pep_service(username);
 	local ok, ret = service:get_items(namespace, session.full_jid);
 	if not ok then
-		if ret == "item-not-found" then
-			module:log("debug", "Got no PEP bookmarks item for %s, returning empty private bookmarks", jid);
-			session.send(st.reply(stanza):add_child(query));
-		else
-			module:log("error", "Failed to retrieve PEP bookmarks of %s: %s", jid, ret);
-			session.send(st.error_reply(stanza, "cancel", ret, "Failed to retrive bookmarks from PEP"));
-		end
+		module:log("error", "Failed to retrieve PEP bookmarks of %s: %s", jid, ret);
+		session.send(st.error_reply(stanza, "cancel", ret, "Failed to retrive bookmarks from PEP"));
 		return true;
 	end