diff --git a/lib/relations.js b/lib/relations.js index bb2f520e..2f13cb99 100644 --- a/lib/relations.js +++ b/lib/relations.js @@ -41,8 +41,7 @@ Relation.hasMany = function hasMany(anotherClass, params) { } } } - var methodName = params.as || - i8n.camelize(i8n.pluralize(anotherClass.modelName), true); + var methodName = params.as || i8n.camelize(anotherClass.pluralModelName, true); var fk = params.foreignKey || i8n.camelize(thisClassName + '_id', true); this.relations[methodName] = {