add user.isGithubCool check
if user signs up with github, they become GithubCool.
This commit is contained in:
@ -19,28 +19,14 @@
|
||||
"password": {
|
||||
"type": "string"
|
||||
},
|
||||
"facebook": {
|
||||
"type": "string"
|
||||
},
|
||||
"twitter": {
|
||||
"type": "string"
|
||||
},
|
||||
"google": {
|
||||
"type": "string"
|
||||
},
|
||||
"github": {
|
||||
"type": "string"
|
||||
},
|
||||
"linkedin": {
|
||||
"type": "string"
|
||||
},
|
||||
"tokens": {
|
||||
"type": "array"
|
||||
},
|
||||
"progressTimestamps": {
|
||||
"type": "array",
|
||||
"default": []
|
||||
},
|
||||
"isGithubCool": {
|
||||
"type": "boolean",
|
||||
"default": false
|
||||
},
|
||||
"username": {
|
||||
"type": "string",
|
||||
"lowercase": true,
|
||||
@ -123,12 +109,6 @@
|
||||
"type": "string",
|
||||
"default": ""
|
||||
},
|
||||
"resetPasswordToken": {
|
||||
"type": "string"
|
||||
},
|
||||
"resetPasswordExpires": {
|
||||
"type": "string"
|
||||
},
|
||||
"completedBonfires": {
|
||||
"type": [
|
||||
{
|
||||
@ -170,21 +150,10 @@
|
||||
"type": "number",
|
||||
"default": 0
|
||||
},
|
||||
"needsSomeDataModeled": {
|
||||
"type": "boolean",
|
||||
"default": false
|
||||
},
|
||||
"needsMigration": {
|
||||
"type": "boolean",
|
||||
"default": true
|
||||
},
|
||||
"sendMonthlyEmail": {
|
||||
"type": "boolean",
|
||||
"default": true
|
||||
},
|
||||
"challengesHash": {
|
||||
"type": {}
|
||||
},
|
||||
"currentChallenge": {
|
||||
"type": {}
|
||||
},
|
||||
@ -205,10 +174,6 @@
|
||||
}
|
||||
],
|
||||
"default": []
|
||||
},
|
||||
"uncompletedChallenges": {
|
||||
"type": "array",
|
||||
"default": []
|
||||
}
|
||||
},
|
||||
"validations": [],
|
||||
|
@ -65,6 +65,9 @@ var passportOptions = {
|
||||
if (email) {
|
||||
userObj.email = email;
|
||||
}
|
||||
if (provider === 'github-login') {
|
||||
userObj.isGithubCool = true;
|
||||
}
|
||||
return userObj;
|
||||
}
|
||||
};
|
||||
|
Reference in New Issue
Block a user