summaryrefslogtreecommitdiffstats
path: root/core
diff options
context:
space:
mode:
Diffstat (limited to 'core')
-rwxr-xr-xcore/sli/provider/src/main/java/org/onap/ccsdk/sli/core/sli/provider/MdsalHelper.java5
1 files changed, 4 insertions, 1 deletions
diff --git a/core/sli/provider/src/main/java/org/onap/ccsdk/sli/core/sli/provider/MdsalHelper.java b/core/sli/provider/src/main/java/org/onap/ccsdk/sli/core/sli/provider/MdsalHelper.java
index 94e1425cb..ce8253a5c 100755
--- a/core/sli/provider/src/main/java/org/onap/ccsdk/sli/core/sli/provider/MdsalHelper.java
+++ b/core/sli/provider/src/main/java/org/onap/ccsdk/sli/core/sli/provider/MdsalHelper.java
@@ -299,7 +299,10 @@ public class MdsalHelper {
if (!isAccessible) {
m.setAccessible(true);
}
- Object retList = Map.class.isAssignableFrom(returnType)?new ArrayList(((Map) m.invoke(fromObj)).values()):m.invoke(fromObj);
+ Object retList = m.invoke(fromObj);
+ if ((retList != null) && Map.class.isAssignableFrom(returnType)) {
+ retList = new ArrayList(((Map)retList).values());
+ }
//due duplicated getters with Map and List(deprecated) stop if already mapped
if(!hasAlreadyKeys(props,propNamePfx + "." + fieldName)) {