mirror of
https://github.com/Telecominfraproject/wlan-cloud-services.git
synced 2026-03-21 10:39:26 +00:00
hardened RoutingDatastoreInMemory against NPE
This commit is contained in:
@@ -331,7 +331,13 @@ public class RoutingDatastoreInMemory extends BaseInMemoryDatastore implements R
|
||||
});
|
||||
|
||||
List<EquipmentGatewayRecord> ret = new ArrayList<>();
|
||||
gwIds.forEach(id -> ret.add(idToGatewayMap.get(id).clone()));
|
||||
|
||||
gwIds.forEach(id -> {
|
||||
EquipmentGatewayRecord gw = idToGatewayMap.get(id);
|
||||
if(gw!=null) {
|
||||
ret.add(gw.clone());
|
||||
}
|
||||
});
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user