From 1852be4ef0a099dd847a55de81cc70b811ae6fed Mon Sep 17 00:00:00 2001 From: Garrett Mills Date: Wed, 15 Sep 2021 04:01:48 +0000 Subject: [PATCH] Update 'app/controllers/auth/Oauth2.controller.js' --- app/controllers/auth/Oauth2.controller.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/controllers/auth/Oauth2.controller.js b/app/controllers/auth/Oauth2.controller.js index 71056f5..3b85233 100644 --- a/app/controllers/auth/Oauth2.controller.js +++ b/app/controllers/auth/Oauth2.controller.js @@ -44,7 +44,7 @@ class Oauth2 extends Oauth2Controller { async authorize_get(req, res, next) { const client = await this._get_authorize_client(req) if ( !client ) return this._uniform(res, req.T('auth.unable_to_authorize')) - const uri = new URL(req.query.redirect_uri) + const uri = new URL(Array.isArray(req.query.redirect_uri) ? req.query.redirect_uri[0] : req.query.redirect_uri) const StarshipClient = this.models.get('oauth:Client') const starship_client = await StarshipClient.findOne({ active: true, uuid: client.clientID })