add state attribute to linked oauth
note: a new variable will need to be added to .env 'LINKEDIN_STATE' which is a random string
This commit is contained in:
@ -104,6 +104,9 @@ module.exports = {
|
||||
clientID: process.env.LINKEDIN_ID,
|
||||
clientSecret: process.env.LINKEDIN_SECRET,
|
||||
scope: ['r_fullprofile', 'r_emailaddress'],
|
||||
oAuthOptions: {
|
||||
state: process.ENV.LINKED_STATE
|
||||
},
|
||||
failureFlash: true
|
||||
},
|
||||
'linkedin-link': {
|
||||
@ -118,6 +121,9 @@ module.exports = {
|
||||
clientID: process.env.LINKEDIN_ID,
|
||||
clientSecret: process.env.LINKEDIN_SECRET,
|
||||
scope: ['r_fullprofile', 'r_emailaddress'],
|
||||
authOptions: {
|
||||
state: process.ENV.LINKED_STATE
|
||||
},
|
||||
failureFlash: true
|
||||
}
|
||||
};
|
||||
|
@ -257,8 +257,8 @@ R.keys(passportProviders).map(function(strategy) {
|
||||
* 500 Error Handler.
|
||||
*/
|
||||
|
||||
//if (process.env.NODE_ENV === 'development') {
|
||||
if (true) {
|
||||
// if (process.env.NODE_ENV === 'development') {
|
||||
if (true) { // eslint-disable-line
|
||||
app.use(errorHandler({
|
||||
log: true
|
||||
}));
|
||||
|
Reference in New Issue
Block a user