mirror of
https://github.com/Hessenuk/DiscordTickets.git
synced 2024-11-05 04:13:08 +02:00
feat(http): prompt=none
(closes #507)
This commit is contained in:
parent
1b0b0a22f9
commit
5e5de6b4d9
@ -25,13 +25,7 @@ module.exports = async client => {
|
||||
fastify.states = new Map();
|
||||
fastify.register(oauth, {
|
||||
callbackUri: `${process.env.HTTP_EXTERNAL}/auth/callback`,
|
||||
// checkStateFunction: (req, callback) => {
|
||||
// if (req.query.state === req.cookies['oauth2-redirect-state']) {
|
||||
// callback();
|
||||
// return;
|
||||
// }
|
||||
// callback(new Error('Invalid state'));
|
||||
// },
|
||||
callbackUriParams: { prompt: 'none' },
|
||||
checkStateFunction: async req => {
|
||||
if (req.query.state !== req.cookies['oauth2-redirect-state']) {
|
||||
throw new Error('Invalid state');
|
||||
|
Loading…
Reference in New Issue
Block a user