Skip to content
Snippets Groups Projects
Commit d402a411 authored by Rodrigo Nascimento's avatar Rodrigo Nascimento Committed by Gabriel Engel
Browse files

Fix issue creating users with username from OAuth

Closes #5222
parent bd32c303
No related branches found
No related tags found
No related merge requests found
......@@ -252,6 +252,11 @@ export class CustomOAuth {
return;
}
// User already created or merged
if (user.services && user.services[serviceName] && user.services[serviceName].id === serviceData.id) {
return;
}
if (this.mergeUsers !== true) {
throw new Meteor.Error('CustomOAuth', `User with username ${user.username} already exists`);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment