|
|
@@ -2,6 +2,7 @@
|
|
|
|
|
|
namespace Longyi\Pay\Airwallex\Http\Controllers;
|
|
|
|
|
|
+use Illuminate\Support\Facades\Log;
|
|
|
use Longyi\Pay\Airwallex\Payment\Airwallex;
|
|
|
use Webkul\Checkout\Facades\Cart;
|
|
|
use Webkul\Sales\Models\Order;
|
|
|
@@ -24,11 +25,11 @@ class AirwallexController extends Controller
|
|
|
|
|
|
public function hook()
|
|
|
{
|
|
|
- $param = @file_get_contents('php://input');
|
|
|
- $header = $this->getAllHeaders();
|
|
|
+ $param = request()->getContent();
|
|
|
+ $header = request()->header();
|
|
|
$data = [
|
|
|
- 'timestamp' => $header['x-timestamp'],
|
|
|
- 'signature' => $header['x-signature'],
|
|
|
+ 'timestamp' => $header['x-timestamp'] ?? '',
|
|
|
+ 'signature' => $header['x-signature'] ?? '',
|
|
|
'content' => $param
|
|
|
];
|
|
|
//记录日志
|