null check
diff --git a/src/main/java/org.onosproject.xran/controller/XranControllerImpl.java b/src/main/java/org.onosproject.xran/controller/XranControllerImpl.java
index ed7b0d2..185ad8e 100644
--- a/src/main/java/org.onosproject.xran/controller/XranControllerImpl.java
+++ b/src/main/java/org.onosproject.xran/controller/XranControllerImpl.java
@@ -597,13 +597,13 @@
                     UEContextUpdate ueContextUpdate = recv_pdu.getBody().getUEContextUpdate();
 
                     RnibUe ue = ueMap.get(ueContextUpdate.getMMEUES1APID());
-                    if (hoQueue.keySet().contains(ue.getRanId())) {
+                    if (ue != null && hoQueue.keySet().contains(ue.getRanId())) {
                         CRNTI crnti = ueContextUpdate.getCrnti();
                         hoContextUpdateMap.put(crnti, ueContextUpdate);
                         hoQueue.remove(ue.getRanId());
                     } else {
                         RnibCell cell = xranStore.getCell(ueContextUpdate.getEcgi());
-                        if (ueMap.get(ueContextUpdate.getMMEUES1APID()) == null) {
+                        if (ue == null) {
                             ue = new RnibUe();
                         }