Skip to content

Commit

Permalink
chore(postback): remove logs
Browse files Browse the repository at this point in the history
  • Loading branch information
matheusgnreis committed Feb 19, 2024
1 parent 89fe7b7 commit 9065330
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions functions/routes/pagarme/postback.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,7 @@ exports.post = ({ appSdk }, req, res) => {
const apiKey = config.pagarme_api_key
const verifyBody = qs.stringify(req.body)
const signature = req.headers['x-hub-signature'].replace('sha1=', '')
if (storeId == 51372) {
console.log('Verify body', verifyBody)
console.log('signature', signature)
console.log('api key', apiKey)
console.log('checking pagarme', pagarme.postback.verifySignature(apiKey, verifyBody, signature))
}

if (!pagarme.postback.verifySignature(apiKey, verifyBody, signature) && verifyBody && signature) {
axios({
url: `https://api.pagar.me/1/transactions/${pagarmeTransaction.id}`,
Expand Down

0 comments on commit 9065330

Please sign in to comment.