1
0
Fork 0

Fixed usage of replace in graph-blueprints

This commit is contained in:
Michael Hackstein 2016-03-24 17:10:01 +01:00
parent 28a0fd89a8
commit 582be9e707
1 changed files with 6 additions and 1 deletions

View File

@ -97,7 +97,12 @@ Edge.prototype.setProperty = function (name, value) {
shallow.$label = this._properties.$label;
shallow[name] = value;
// TODO use "update" if this becomes available
if (this._properties.hasOwnProperty('_from')) {
shallow._from = this._properties._from;
}
if (this._properties.hasOwnProperty('_to')) {
shallow._to = this._properties._to;
}
id = this._graph._edges.replace(this._properties, shallow);
this._properties = this._graph._edges.document(id);