Some error checks
parent
a49258e840
commit
d09e7f5565
|
|
@ -368,7 +368,9 @@ async function setupAuth()
|
|||
app.get(
|
||||
'/auth/callback',
|
||||
passport.authenticate('oidc', { failureRedirect: '/auth/login' }),
|
||||
async (req, res) =>
|
||||
async (req, res, next) =>
|
||||
{
|
||||
try
|
||||
{
|
||||
const state = JSON.parse(base64.decode(req.query.state));
|
||||
|
||||
|
|
@ -401,6 +403,11 @@ async function setupAuth()
|
|||
picture : peer.picture
|
||||
}));
|
||||
}
|
||||
catch (error)
|
||||
{
|
||||
return next(error);
|
||||
}
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
|
|
@ -586,6 +593,7 @@ async function runWebSocketServer()
|
|||
{
|
||||
logger.error('room creation or room joining failed [error:"%o"]', error);
|
||||
|
||||
if (socket)
|
||||
socket.disconnect(true);
|
||||
|
||||
return;
|
||||
|
|
|
|||
Loading…
Reference in New Issue