From af02440c40991b8e214e38e8906d262f5969951c Mon Sep 17 00:00:00 2001 From: Francisco Coelho Date: Mon, 12 Sep 2022 09:31:44 +0100 Subject: [PATCH] Revert "Update credentialed.js" This reverts commit eeac1200e7aa22c94a4f3992a58f440eb7f3f2b5. --- src/utils/proxies/credentialed.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/utils/proxies/credentialed.js b/src/utils/proxies/credentialed.js index 847a7f3e4..d263adf0d 100644 --- a/src/utils/proxies/credentialed.js +++ b/src/utils/proxies/credentialed.js @@ -3,13 +3,13 @@ import { formatApiCall } from "utils/api-helpers"; import { httpProxy } from "utils/http"; export default async function credentialedProxyHandler(req, res) { - let headersData const { group, service, endpoint } = req.query; if (group && service) { const widget = await getServiceWidget(group, service); - if(widget.type === "gotify"){ + var headersData + if(widget.type == "gotify"){ headersData = {"X-gotify-Key": `${widget.key}`,"Content-Type": "application/json",} }else{ headersData = {"X-API-Key": `${widget.key}`,"Content-Type": "application/json",}