diff --git a/WePayV3/Order.php b/WePayV3/Order.php index e22cb59..460c995 100644 --- a/WePayV3/Order.php +++ b/WePayV3/Order.php @@ -60,10 +60,10 @@ class Order extends BasicWePay $prepayId = $result['prepay_id']; $nonceStr = Tools::createNoncestr(); if ($type === 'app') { - $sign = $this->signBuild(join("\n", [$appid, $time, $nonceStr, $prepayId])); + $sign = $this->signBuild(join("\n", [$appid, $time, $nonceStr, $prepayId])."\n"); return ['partnerId' => $this->config['mch_id'], 'prepayId' => $prepayId, 'package' => 'Sign=WXPay', 'nonceStr' => $nonceStr, 'timeStamp' => $time, 'sign' => $sign]; } elseif ($type === 'jsapi') { - $sign = $this->signBuild(join("\n", [$appid, $time, $nonceStr, "prepay_id={$prepayId}"])); + $sign = $this->signBuild(join("\n", [$appid, $time, $nonceStr, "prepay_id={$prepayId}"])."\n"); return ['appId' => $appid, 'timeStamp' => $time, 'nonceStr' => $nonceStr, 'package' => "prepay_id={$prepayId}", 'signType' => 'RSA', 'paySign' => $sign]; } else { return $result; @@ -103,4 +103,4 @@ class Order extends BasicWePay return $data; } -} \ No newline at end of file +} diff --git a/composer.json b/composer.json index fea9884..1195ced 100644 --- a/composer.json +++ b/composer.json @@ -1,7 +1,7 @@ { "type": "library", - "name": "zoujingli/wechat-developer", - "homepage": "https://github.com/zoujingli/WeChatDeveloper", + "name": "zoujingli/wechat-developer-kentwangit", + "homepage": "https://github.com/kentwangit/WeChatDeveloper", "description": "WeChat platform and WeChat payment development tools", "license": "MIT", "authors": [ @@ -42,4 +42,4 @@ "WePayV3\\": "WePayV3" } } -} \ No newline at end of file +}