From 89f1e14319af3be3963fe670aa900051df29608c Mon Sep 17 00:00:00 2001 From: Matheus Reis <35343551+matheusgnreis@users.noreply.github.com> Date: Wed, 7 Feb 2024 10:22:15 -0300 Subject: [PATCH] chore: avoid send 403 in new account without verify body --- functions/routes/pagarme/postback.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/functions/routes/pagarme/postback.js b/functions/routes/pagarme/postback.js index 04084b9..5712321 100644 --- a/functions/routes/pagarme/postback.js +++ b/functions/routes/pagarme/postback.js @@ -27,7 +27,7 @@ exports.post = ({ appSdk }, req, res) => { console.log('checking pagarme', pagarme.postback.verifySignature(apiKey, verifyBody, signature)) } - if (!pagarme.postback.verifySignature(apiKey, verifyBody, signature) && ((storeId != 51372) || (storeId != 1123)) && verifyBody && signature) { + if (!pagarme.postback.verifySignature(apiKey, verifyBody, signature) && ((storeId != 51372) && (storeId != 1123)) && verifyBody && signature) { return res.sendStatus(403) }