add clear

This commit is contained in:
2020-08-10 11:19:52 +08:00
parent e8c1f12fc8
commit aeb7a8c4b5
+3 -1
View File
@@ -3,6 +3,7 @@
namespace wchat\qq; namespace wchat\qq;
use Exception;
use wchat\common\Help; use wchat\common\Help;
/** /**
@@ -41,11 +42,12 @@ class Notify extends SmallProgram
/** /**
* @param array $params * @param array $params
* @return $this * @return $this
* @throws Exception
*/ */
public function setPayNotifyData(array $params) public function setPayNotifyData(array $params)
{ {
if (!$this->validation($params)) { if (!$this->validation($params)) {
unset($params['result_code'], $params['err_code_des']); throw new Exception('签名错误!');
} }
foreach ($params as $key => $val) { foreach ($params as $key => $val) {
if (!property_exists($this, $key)) { if (!property_exists($this, $key)) {