From 95ca419d17d074d1a1b04f0ed26396b0f4838dc1 Mon Sep 17 00:00:00 2001 From: ayyoob Date: Thu, 28 Jul 2016 15:46:23 +0530 Subject: [PATCH] avoided null check when comparing --- .../device/mgt/iot/virtualfirealarm/plugin/xmpp/XmppConfig.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/iot-plugins/virtual-fire-alarm-plugin/org.wso2.carbon.device.mgt.iot.virtualfirealarm.plugin/src/main/java/org/wso2/carbon/device/mgt/iot/virtualfirealarm/plugin/xmpp/XmppConfig.java b/components/iot-plugins/virtual-fire-alarm-plugin/org.wso2.carbon.device.mgt.iot.virtualfirealarm.plugin/src/main/java/org/wso2/carbon/device/mgt/iot/virtualfirealarm/plugin/xmpp/XmppConfig.java index aed81d1e38..2ac57e0b8f 100644 --- a/components/iot-plugins/virtual-fire-alarm-plugin/org.wso2.carbon.device.mgt.iot.virtualfirealarm.plugin/src/main/java/org/wso2/carbon/device/mgt/iot/virtualfirealarm/plugin/xmpp/XmppConfig.java +++ b/components/iot-plugins/virtual-fire-alarm-plugin/org.wso2.carbon.device.mgt.iot.virtualfirealarm.plugin/src/main/java/org/wso2/carbon/device/mgt/iot/virtualfirealarm/plugin/xmpp/XmppConfig.java @@ -45,7 +45,7 @@ public class XmppConfig { List properties = deviceManagementConfiguration.getPushNotificationConfig() .getProperties(); String provider = deviceManagementConfiguration.getPushNotificationConfig().getPushNotificationProvider(); - if (provider.equals("XMPP")) { + if ("XMPP".equals(provider)) { enabled = true; } if (enabled) {