From 1ba64e02fe0f8063dcb3a0fa8b356fe82575a6b2 Mon Sep 17 00:00:00 2001 From: Michael Shanks Date: Mon, 18 May 2020 11:53:04 +0100 Subject: [PATCH] removing Authorization header --- packages/server/src/middleware/authenticated.js | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/packages/server/src/middleware/authenticated.js b/packages/server/src/middleware/authenticated.js index 43c8f013e1..1bcc5575c3 100644 --- a/packages/server/src/middleware/authenticated.js +++ b/packages/server/src/middleware/authenticated.js @@ -3,14 +3,7 @@ const STATUS_CODES = require("../utilities/statusCodes") const env = require("../environment") module.exports = async (ctx, next) => { - const authHeader = ctx.get("Authorization") - - if ( - authHeader && - authHeader.startsWith("Basic") && - authHeader.split(" ")[1] === env.ADMIN_SECRET - ) { - ctx.isAuthenticated = true + if (ctx.path === "/_builder") { await next() return }