From 9617472d697fe92b475a08ee3b196a5a66878cae Mon Sep 17 00:00:00 2001 From: Vitaly Takmazov Date: Tue, 10 Oct 2017 09:51:19 +0300 Subject: xmpp: fix NPE --- juick-xmpp/src/main/java/com/juick/components/JuickBot.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'juick-xmpp/src/main/java/com') diff --git a/juick-xmpp/src/main/java/com/juick/components/JuickBot.java b/juick-xmpp/src/main/java/com/juick/components/JuickBot.java index f79db78e..205e3f90 100644 --- a/juick-xmpp/src/main/java/com/juick/components/JuickBot.java +++ b/juick-xmpp/src/main/java/com/juick/components/JuickBot.java @@ -209,7 +209,7 @@ public class JuickBot implements StanzaListener, AutoCloseable { } if (msg.getType() != null && msg.getType().equals(Message.Type.ERROR)) { StanzaError error = msg.getExtension(StanzaError.class); - if (error.getCondition().equals(Condition.RESOURCE_CONSTRAINT)) { + if (error != null && error.getCondition().equals(Condition.RESOURCE_CONSTRAINT)) { // offline query is full, deactivating this jid if (userService.setActiveStatusForJID(msg.getFrom().toEscapedString(), UserService.ActiveStatus.Inactive)) { logger.info("{} is inactive now", msg.getFrom()); -- cgit v1.2.3