Fix HasOne.update to propagate options arg
This commit is contained in:
parent
f6c054e3f4
commit
839a2c6c66
|
@ -1745,7 +1745,7 @@ HasOne.prototype.update = function(targetModelData, options, cb) {
|
|||
this.fetch(function(err, targetModel) {
|
||||
if (targetModel instanceof ModelBaseClass) {
|
||||
delete targetModelData[fk];
|
||||
targetModel.updateAttributes(targetModelData, cb);
|
||||
targetModel.updateAttributes(targetModelData, options, cb);
|
||||
} else {
|
||||
cb(new Error(g.f('{{HasOne}} relation %s is empty', definition.name)));
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue