mod_groups_internal: Fix traceback when room doesn't exist
I'm not sure if it should even be included if it doesn't exist, but I'm not
currently sure how this situation occurs, so I'm implementing the lightest
possible fix for now.
--- a/mod_groups_internal/mod_groups_internal.lua Tue Jan 09 13:50:18 2024 +0000
+++ b/mod_groups_internal/mod_groups_internal.lua Thu Jan 11 15:53:18 2024 +0000
@@ -422,10 +422,11 @@
end
return array.map(mucs, function (muc_jid)
+ local room = muc_host.get_room_from_jid(muc_jid);
return {
id = jid.node(muc_jid);
jid = muc_jid;
- name = muc_host.get_room_from_jid(muc_jid):get_name() or group_info.name;
+ name = room and room:get_name() or group_info.name;
};
end);
end