Skip to content

Commit 8e1ee56

Browse files
authored
The fields "shipping" and "tax" can both be float values (#19)
Hi @aawnu, these two fields can be floats according to the documentation. I've fixed the annotations in the interface as well.
2 parents a5e1481 + 08d8f86 commit 8e1ee56

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

src/Event/Purchase.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -93,13 +93,13 @@ public function setCoupon(string $code)
9393
return $this;
9494
}
9595

96-
public function setShipping(int $cost)
96+
public function setShipping(float $cost)
9797
{
9898
$this->shipping = 0 + $cost;
9999
return $this;
100100
}
101101

102-
public function setTax(int $tax)
102+
public function setTax(float $tax)
103103
{
104104
$this->tax = $tax;
105105
return $this;

src/Facade/Purchase.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -56,17 +56,17 @@ public function setCoupon(string $code);
5656
* Shipping cost associated with a transaction.
5757
*
5858
* @var shipping
59-
* @param string $cost eg. 3.33
59+
* @param float $cost eg. 3.33
6060
*/
61-
public function setShipping(int $cost);
61+
public function setShipping(float $cost);
6262

6363
/**
6464
* Tax cost associated with a transaction.
6565
*
6666
* @var tax
67-
* @param string $tax eg. 1.11
67+
* @param float $tax eg. 1.11
6868
*/
69-
public function setTax(int $tax);
69+
public function setTax(float $tax);
7070

7171
/**
7272
* The items for the event.

0 commit comments

Comments
 (0)