|
|
@@ -751,15 +751,12 @@ module.exports = (crowi) => {
|
|
|
twitterConsumerSecret: await crowi.configManager.getConfig('crowi', 'security:passport-twitter:consumerSecret'),
|
|
|
isSameUsernameTreatedAsIdenticalUser: await crowi.configManager.getConfig('crowi', 'security:passport-twitter:isSameUsernameTreatedAsIdenticalUser'),
|
|
|
};
|
|
|
-
|
|
|
// reset strategy
|
|
|
await crowi.passportService.resetTwitterStrategy();
|
|
|
-
|
|
|
// setup strategy
|
|
|
if (crowi.configManager.getConfig('crowi', 'security:passport-twitter:isEnabled')) {
|
|
|
await crowi.passportService.setupTwitterStrategy(true);
|
|
|
}
|
|
|
-
|
|
|
return res.apiv3({ securitySettingParams });
|
|
|
}
|
|
|
catch (err) {
|
|
|
@@ -769,8 +766,6 @@ module.exports = (crowi) => {
|
|
|
logger.error('Error', err);
|
|
|
return res.apiv3Err(new ErrorV3(msg, 'update-twitterOAuth-failed'));
|
|
|
}
|
|
|
-
|
|
|
-
|
|
|
});
|
|
|
|
|
|
return router;
|