mirror of
https://github.com/nasa/openmct.git
synced 2025-01-11 23:42:41 +00:00
Fixed error with not properly referenced
This commit is contained in:
parent
cee0ecf0ef
commit
3b427c31a2
@ -104,14 +104,10 @@ define(
|
|||||||
function addClonesToParent(self) {
|
function addClonesToParent(self) {
|
||||||
var parentClone = self.clones[self.clones.length-1];
|
var parentClone = self.clones[self.clones.length-1];
|
||||||
|
|
||||||
//self.persistenceService
|
return parentClone.getCapability("persistence").persist()
|
||||||
// .updateObject(self.persistenceSpace,
|
.then(function(){self.parent.getCapability("composition").add(parentClone.getId())})
|
||||||
// parentClone.id, parentClone.model)
|
.then(function(){return self.parent.getCapability("persistence").persist();})
|
||||||
return parentClone.getCapability("persistence").persist()
|
.then(function(){return parentClone;});
|
||||||
.then(function(){self.parent.getCapability("composition").add(parentClone.getId())})
|
|
||||||
.then(function(){return self.parent.getCapability("persistence").persist();})
|
|
||||||
.then(function(){return parentClone;});
|
|
||||||
// Ensure the clone of the original domainObject is returned
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -175,7 +171,7 @@ define(
|
|||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
//Creating a link, no need to iterate children
|
//Creating a link, no need to iterate children
|
||||||
return $q.when(originalObject);
|
return self.$q.when(originalObject);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user