mirror of
https://github.com/strapi/strapi.git
synced 2025-11-11 07:39:16 +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`;
|
return `${strapi.backendURL}/connect/google/callback`;
|
||||||
case 'github':
|
case 'github':
|
||||||
return get(this.props.values, 'redirect_uri', '');
|
return get(this.props.values, 'redirect_uri', '');
|
||||||
|
case 'discord':
|
||||||
|
return `${strapi.backendURL}/connect/discord/callback`;
|
||||||
default: {
|
default: {
|
||||||
const value = get(this.props.values, 'callback', '');
|
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.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.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.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.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",
|
"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'
|
'user:email'
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
discord: {
|
||||||
|
enabled: false,
|
||||||
|
icon: 'discord',
|
||||||
|
key: '',
|
||||||
|
secret: '',
|
||||||
|
callback: '/auth/discord/callback',
|
||||||
|
scope: ['email']
|
||||||
|
},
|
||||||
twitter: {
|
twitter: {
|
||||||
enabled: false,
|
enabled: false,
|
||||||
icon: 'twitter',
|
icon: 'twitter',
|
||||||
|
|||||||
@ -174,6 +174,12 @@ const getProfile = async (provider, query, callback) => {
|
|||||||
});
|
});
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
case 'discord': {
|
||||||
|
const discord = new Purest({
|
||||||
|
provider: 'discord',
|
||||||
|
|
||||||
|
})
|
||||||
|
}
|
||||||
case 'twitter': {
|
case 'twitter': {
|
||||||
const twitter = new Purest({
|
const twitter = new Purest({
|
||||||
provider: 'twitter',
|
provider: 'twitter',
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user