|
|
@ -148,9 +148,11 @@
|
|
|
|
for (var i in login_strategies) {
|
|
|
|
for (var i in login_strategies) {
|
|
|
|
if (login_strategies.hasOwnProperty(i)) {
|
|
|
|
if (login_strategies.hasOwnProperty(i)) {
|
|
|
|
var strategy = login_strategies[i];
|
|
|
|
var strategy = login_strategies[i];
|
|
|
|
|
|
|
|
if (strategy.url) {
|
|
|
|
app.get(strategy.url, passport.authenticate(strategy.name, {
|
|
|
|
app.get(strategy.url, passport.authenticate(strategy.name, {
|
|
|
|
scope: strategy.scope
|
|
|
|
scope: strategy.scope
|
|
|
|
}));
|
|
|
|
}));
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
app.get(strategy.callbackURL, passport.authenticate(strategy.name, {
|
|
|
|
app.get(strategy.callbackURL, passport.authenticate(strategy.name, {
|
|
|
|
successRedirect: nconf.get('relative_path') + '/',
|
|
|
|
successRedirect: nconf.get('relative_path') + '/',
|
|
|
|