diff --git a/src/main/java/eu/siacs/conversations/entities/Conversation.java b/src/main/java/eu/siacs/conversations/entities/Conversation.java index ac35f7faf01037df31f5283efd40c9f9710da8f0..0ff56e2892fb5eddd33e8e1734b8710fc983feea 100644 --- a/src/main/java/eu/siacs/conversations/entities/Conversation.java +++ b/src/main/java/eu/siacs/conversations/entities/Conversation.java @@ -2582,15 +2582,17 @@ public class Conversation extends AbstractEntity implements Blockable, Comparabl xmppConnectionService.getPreferences().edit().putBoolean("onboarding_continued", true).commit(); } - for (Element el : command.getChildren()) { - if (el.getName().equals("actions") && el.getNamespace().equals("http://jabber.org/protocol/commands")) { - for (Element action : el.getChildren()) { - if (!el.getNamespace().equals("http://jabber.org/protocol/commands")) continue; - if (action.getName().equals("execute")) continue; + Element actions = command.findChild("actions", "http://jabber.org/protocol/commands"); + if (actions != null) { + for (Element action : actions.getChildren()) { + if (!"http://jabber.org/protocol/commands".equals(action.getNamespace())) continue; + if ("execute".equals(action.getName())) continue; - actionsAdapter.add(Pair.create(action.getName(), action.getName())); - } + actionsAdapter.add(Pair.create(action.getName(), action.getName())); } + } + + for (Element el : command.getChildren()) { if (el.getName().equals("x") && el.getNamespace().equals("jabber:x:data")) { Data form = Data.parse(el); String title = form.getTitle();