Skip to content

Commit c1e489b

Browse files
authored
PHPSDK-173: Fix typo in \MultiSafepay\Api\Transactions\OrderRequest\Arguments\GatewayInfo\Creditcard object (#378)
1 parent e915bae commit c1e489b

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

src/Api/Transactions/OrderRequest/Arguments/GatewayInfo/Creditcard.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -147,8 +147,8 @@ public function getData(): array
147147
{
148148
return [
149149
'card_number' => $this->cardNumber ? $this->cardNumber->get() : null,
150-
'cart_holder_name' => $this->cardHolderName,
151-
'cart_expiry_date' => $this->cardExpiryDate ? $this->cardExpiryDate->get('my') : null,
150+
'card_holder_name' => $this->cardHolderName,
151+
'card_expiry_date' => $this->cardExpiryDate ? $this->cardExpiryDate->get('ym') : null,
152152
'cvc' => $this->cvc ? $this->cvc->get() : null,
153153
'card_cvc' => $this->cvc ? $this->cvc->get() : null,
154154
'flexible_3d' => $this->flexible3d,

tests/Unit/Api/Transactions/OrderRequest/Arguments/GatewayInfo/CreditcardTest.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,8 @@ public function testGetData()
3131
$creditcard->addFlexible3d(true);
3232
$creditcard->addTermUrl('http://example.org/');
3333
$data = $creditcard->getData();
34-
$this->assertSame('0101', $data['cart_expiry_date']);
35-
$this->assertSame('John Doe', $data['cart_holder_name']);
34+
$this->assertSame('0101', $data['card_expiry_date']);
35+
$this->assertSame('John Doe', $data['card_holder_name']);
3636
$this->assertSame($creditcardNumber, $data['card_number']);
3737
$this->assertSame('111', $data['cvc']);
3838
$this->assertSame(true, $data['flexible_3d']);
@@ -56,7 +56,7 @@ public function testSettingValueObjectsUsingAsStringMethods()
5656
$creditcard->addCvcAsString('111');
5757

5858
$data = $creditcard->getData();
59-
$this->assertSame('0101', $data['cart_expiry_date']);
59+
$this->assertSame('0101', $data['card_expiry_date']);
6060
$this->assertSame($creditcardNumber, $data['card_number']);
6161
$this->assertSame('111', $data['cvc']);
6262
}

0 commit comments

Comments
 (0)