Skip to content

Commit 8cf7f9e

Browse files
committed
fix(server): fix oauth PR
1 parent 5cbd603 commit 8cf7f9e

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

Diff for: templates/app/server/api/user(auth)/user.model(mongooseModels).js

+2-1
Original file line numberDiff line numberDiff line change
@@ -95,9 +95,10 @@ UserSchema
9595
.path('email')
9696
.validate(function(value, respond) {
9797
var self = this;
98+
<%_ if(filters.oauth) { _%>
9899
if (authTypes.indexOf(this.provider) !== -1) {
99100
return respond(true);
100-
}
101+
}<% } %>
101102
return this.constructor.findOne({ email: value }).exec()
102103
.then(function(user) {
103104
if (user) {

0 commit comments

Comments
 (0)