1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-01-11 00:08:30 +01:00

fix: don't apply bearer token middleware to root (#6939)

Conflicts with scim which assumes Bearer <token>, and is located under
/scim, with no /api prefix
This commit is contained in:
Christopher Kolstad 2024-04-25 16:56:51 +02:00 committed by GitHub
parent 2400ffc67e
commit cb40f35aeb
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -61,7 +61,7 @@ export default async function getApp(
app.use(requestLogger(config));
app.use(bearerTokenMiddleware(config));
app.use('/api', bearerTokenMiddleware(config)); // We only need bearer token compatibility on /api paths.
if (typeof config.preHook === 'function') {
config.preHook(app, config, services, db);