diff --git a/lib/relation-definition.js b/lib/relation-definition.js index 3185a6a4..e32bd253 100644 --- a/lib/relation-definition.js +++ b/lib/relation-definition.js @@ -391,13 +391,13 @@ util.inherits(HasOne, Relation); * EmbedsOne subclass * @param {RelationDefinition|Object} definition * @param {Object} modelInstance - * @returns {EmbedsMany} + * @returns {EmbedsOne} * @constructor * @class EmbedsOne */ function EmbedsOne(definition, modelInstance) { if (!(this instanceof EmbedsOne)) { - return new EmbedsMany(definition, modelInstance); + return new EmbedsOne(definition, modelInstance); } assert(definition.type === RelationTypes.embedsOne); Relation.apply(this, arguments);