From 079f2e52554336f550d70af8c7e6f3f310cfd696 Mon Sep 17 00:00:00 2001 From: weigang Date: Wed, 26 Aug 2020 17:54:53 +0800 Subject: [PATCH] fix --- app/Controller/NotifyController.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/app/Controller/NotifyController.php b/app/Controller/NotifyController.php index 1ddfb11..1073dc2 100644 --- a/app/Controller/NotifyController.php +++ b/app/Controller/NotifyController.php @@ -115,7 +115,7 @@ class NotifyController extends BaseController $message ); Db::rollBack(); - $fail('Unknown error but FAIL'); + return $fail('Unknown error but FAIL'); } // 查询订单 @@ -127,7 +127,7 @@ class NotifyController extends BaseController ->first(); // 订单不存在 - if (empty($orderMain)) { + if (empty($orderMain) || $orderMain->state == OrderMain::ORDER_STATE_DELIVERY) { $this->log->event( LogLabel::PAY_NOTIFY_WXMINI, ['global_order_id_fail' => $message['out_trade_no']] @@ -222,7 +222,7 @@ class NotifyController extends BaseController ['exception_fail' => $e->getMessage()] ); Db::rollBack(); - $fail('Exception'); + return $fail('Exception'); } }); @@ -267,7 +267,7 @@ class NotifyController extends BaseController $message ); Db::rollBack(); - $fail('Unknown error but FAIL'); + return $fail('Unknown error but FAIL'); } // 查询订单 @@ -397,7 +397,7 @@ class NotifyController extends BaseController ['exception_fail' => $e->getMessage()] ); Db::rollBack(); - $fail('Exception'); + return $fail('Exception'); } });