mirror of
https://github.com/strapi/strapi.git
synced 2025-11-02 10:55:37 +00:00
Add base structure for discord
This commit is contained in:
parent
2fbb6027bd
commit
4c64168cda
@ -49,6 +49,8 @@ class PopUpForm extends React.Component { // eslint-disable-line react/prefer-st
|
||||
return `${strapi.backendURL}/connect/google/callback`;
|
||||
case 'github':
|
||||
return get(this.props.values, 'redirect_uri', '');
|
||||
case 'discord':
|
||||
return `${strapi.backendURL}/connect/discord/callback`;
|
||||
default: {
|
||||
const value = get(this.props.values, 'callback', '');
|
||||
|
||||
|
||||
@ -166,6 +166,7 @@
|
||||
"PopUpForm.Providers.facebook.providerConfig.redirectURL": "The redirect URL to add in your Facebook application configurations",
|
||||
"PopUpForm.Providers.google.providerConfig.redirectURL": "The redirect URL to add in your Google application configurations",
|
||||
"PopUpForm.Providers.github.providerConfig.redirectURL": "The redirect URL to add in your GitHub application configurations",
|
||||
"PopUpForm.Providers.discord.providerConfig.redirectURL": "The redirect URL to add in your Discord application configurations",
|
||||
"PopUpForm.Providers.linkedin2.providerConfig.redirectURL": "The redirect URL to add in your Linkedin application configurations",
|
||||
"PopUpForm.Providers.twitter.providerConfig.redirectURL": "The redirect URL to add in your Twitter application configurations",
|
||||
|
||||
|
||||
@ -66,6 +66,14 @@ module.exports = async cb => {
|
||||
'user:email'
|
||||
]
|
||||
},
|
||||
discord: {
|
||||
enabled: false,
|
||||
icon: 'discord',
|
||||
key: '',
|
||||
secret: '',
|
||||
callback: '/auth/discord/callback',
|
||||
scope: ['email']
|
||||
},
|
||||
twitter: {
|
||||
enabled: false,
|
||||
icon: 'twitter',
|
||||
|
||||
@ -174,6 +174,12 @@ const getProfile = async (provider, query, callback) => {
|
||||
});
|
||||
break;
|
||||
}
|
||||
case 'discord': {
|
||||
const discord = new Purest({
|
||||
provider: 'discord',
|
||||
|
||||
})
|
||||
}
|
||||
case 'twitter': {
|
||||
const twitter = new Purest({
|
||||
provider: 'twitter',
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user