@@ -343,8 +343,7 @@ |
||
343 | 343 | |
344 | 344 | if (null !== $card->number) { |
345 | 345 | $lastDigits = strlen($card->number) <= 4 |
346 | - ? $card->number : |
|
347 | - substr($card->number, -4); |
|
346 | + ? $card->number : substr($card->number, -4); |
|
348 | 347 | $card->number = "XXXX-XXXX-XXXX-" . $lastDigits; |
349 | 348 | } |
350 | 349 |
@@ -160,6 +160,9 @@ discard block |
||
160 | 160 | return false; |
161 | 161 | } |
162 | 162 | |
163 | + /** |
|
164 | + * @param string $prop |
|
165 | + */ |
|
163 | 166 | private function with($prop, $value) |
164 | 167 | { |
165 | 168 | $card = clone $this; |
@@ -207,7 +210,6 @@ discard block |
||
207 | 210 | /** |
208 | 211 | * Sets card holder first name. |
209 | 212 | * |
210 | - * @param string $firstName |
|
211 | 213 | * @return CreditCard |
212 | 214 | */ |
213 | 215 | public function withHolderName($holderName) |
@@ -219,7 +221,7 @@ discard block |
||
219 | 221 | /** |
220 | 222 | * Gets expiry date card. |
221 | 223 | * |
222 | - * @return ExpireDate |
|
224 | + * @return ExpiryDate |
|
223 | 225 | */ |
224 | 226 | public function getExpiryDate() |
225 | 227 | { |
@@ -46,7 +46,7 @@ |
||
46 | 46 | public function __construct($month, $year) |
47 | 47 | { |
48 | 48 | $pad = "20"; # Since expiration would be in future, assuming start millenium is 2000. |
49 | - # Please correct this accordingly in next millenium :P. |
|
49 | + # Please correct this accordingly in next millenium :P. |
|
50 | 50 | $this->year = (int) str_pad($year, 4, $pad, STR_PAD_LEFT); |
51 | 51 | $this->month = (int) $month; |
52 | 52 |