Skip to content

Commit 9a8e4eb

Browse files
committed
Fix error while pairing with server
This commit fixes a TypeError thrown by GuzzleHttp due to a malformed 'headers' array supplied in the pairing request to BitPay's server
1 parent 6101ec3 commit 9a8e4eb

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Commands/CreateKeypair.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -153,8 +153,8 @@ public function pairWithServerAndCreateToken()
153153
$response = $bitpayClient->post('/tokens', [
154154
'json' => $postData,
155155
'headers' => [
156-
'x-accept-version: 2.0.0',
157-
'Content-Type: application/json',
156+
'x-accept-version' => '2.0.0',
157+
'Content-Type' => 'application/json',
158158
// Todo: If added below headers, bitpay responds with error, "This endpoint does not support the `user` facade"
159159
// 'x-identity' => $this->publicKey->__toString(),
160160
// 'x-signature' => $this->privateKey->sign($this->network.'/tokens'.json_encode($postData)),

0 commit comments

Comments
 (0)