} else if (obj instanceof Collection) {
return (T) load((Collection<T>)obj, recursive, update);
} else if(obj instanceof Pager) {
- load(((Pager)obj).getRecords(), recursive, update);
- return obj;
+ load(((Pager)obj).getRecords(), recursive, update);
+ return obj;
} else if(obj instanceof MergeResult) {
return (T) load((MergeResult<CdmBase>)obj, recursive, update);
}
return map;
}
- public <T extends Object> Collection<T> load(Collection<T> collection, boolean recursive, boolean update){
+ public <T extends Object> Collection<T> load(Collection<T> collection, boolean recursive, boolean update){
Collection<T> loadedCollection;
if(isRecursiveEnabled && recursive) {
CdmBase cachedCdmEntityInSubGraph = cdmCacher.getFromCache(cdmEntityInSubGraph);
if(cachedCdmEntityInSubGraph != null) {
- if(cachedCdmEntityInSubGraph != cdmEntityInSubGraph) {
+ if(!cachedCdmEntityInSubGraph.equals(cdmEntityInSubGraph)) {
// exception : is the case where
// the field has been already initialised, cached and
// is not the same as the one in the cache, in which case we set the value