Lookup the email model

This commit is contained in:
Raymond Feng 2014-01-23 14:40:27 -08:00
parent bcc7e68e0e
commit bb389ce209
1 changed files with 1 additions and 1 deletions

View File

@ -246,7 +246,7 @@ User.prototype.verify = function (options, fn) {
// Email model
var Email = options.mailer || this.constructor.email || loopback.Email;
var Email = options.mailer || this.constructor.email || loopback.getModelByType(loopback.Email);
crypto.randomBytes(64, function(err, buf) {
if(err) {