From d74aaff73d323fd931aab73597f2c51278ac9529 Mon Sep 17 00:00:00 2001 From: lyt Date: Thu, 23 May 2019 18:57:00 +0800 Subject: [PATCH] =?UTF-8?q?PayPal=20webhook=20=E4=B8=8D=E5=8F=91=E9=82=AE?= =?UTF-8?q?=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- webht/third_party/paypal/controllers/index.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/webht/third_party/paypal/controllers/index.php b/webht/third_party/paypal/controllers/index.php index 1339cd14..1677ced4 100644 --- a/webht/third_party/paypal/controllers/index.php +++ b/webht/third_party/paypal/controllers/index.php @@ -962,7 +962,9 @@ class Index extends CI_Controller { //添加邮件发送记录 - if ($item->pn_send !== 'send') { + $webhook_memo = json_decode($item->pn_memo); + $is_webhook = substr($webhook_memo->id, 0, 2)==="WH" ? true : false; + if ($item->pn_send !== 'send' && false===$is_webhook) { //给外联发送通知邮件 $fromName = !empty($item->pn_payer) ? $item->pn_payer : ''; $fromEmail = !empty($item->pn_payer_email) ? $item->pn_payer_email : '';