Skip to content

Commit d6434db

Browse files
committed
Apply fixes from StyleCI
1 parent e1dc089 commit d6434db

12 files changed

+74
-67
lines changed

src/CardCvc.php

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,8 @@ public function __construct($card_number)
2626
/**
2727
* Determine if the validation rule passes.
2828
*
29-
* @param string $attribute
30-
* @param mixed $value
31-
*
29+
* @param string $attribute
30+
* @param mixed $value
3231
* @return bool
3332
*/
3433
public function passes($attribute, $value)

src/CardExpirationDate.php

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ class CardExpirationDate implements Rule
2222
/**
2323
* CardExpirationDate constructor.
2424
*
25-
* @param string $format Date format
25+
* @param string $format Date format
2626
*/
2727
public function __construct(string $format)
2828
{
@@ -33,9 +33,8 @@ public function __construct(string $format)
3333
/**
3434
* Determine if the validation rule passes.
3535
*
36-
* @param string $attribute
37-
* @param mixed $value
38-
*
36+
* @param string $attribute
37+
* @param mixed $value
3938
* @return bool
4039
*/
4140
public function passes($attribute, $value)

src/CardExpirationMonth.php

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ class CardExpirationMonth implements Rule
1818
/**
1919
* CardExpirationMonth constructor.
2020
*
21-
* @param string $year
21+
* @param string $year
2222
*/
2323
public function __construct($year)
2424
{
@@ -28,9 +28,8 @@ public function __construct($year)
2828
/**
2929
* Determine if the validation rule passes.
3030
*
31-
* @param string $attribute
32-
* @param mixed $value
33-
*
31+
* @param string $attribute
32+
* @param mixed $value
3433
* @return bool
3534
*/
3635
public function passes($attribute, $value)

src/CardExpirationYear.php

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ class CardExpirationYear implements Rule
1818
/**
1919
* CardExpirationYear constructor.
2020
*
21-
* @param string $month
21+
* @param string $month
2222
*/
2323
public function __construct($month)
2424
{
@@ -28,9 +28,8 @@ public function __construct($month)
2828
/**
2929
* Determine if the validation rule passes.
3030
*
31-
* @param string $attribute
32-
* @param mixed $value
33-
*
31+
* @param string $attribute
32+
* @param mixed $value
3433
* @return bool
3534
*/
3635
public function passes($attribute, $value)

src/CardNumber.php

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,8 @@ class CardNumber implements Rule
1919
/**
2020
* Determine if the validation rule passes.
2121
*
22-
* @param string $attribute
23-
* @param mixed $value
24-
*
22+
* @param string $attribute
23+
* @param mixed $value
2524
* @return bool
2625
*/
2726
public function passes($attribute, $value)

src/Cards/Card.php

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ abstract class Card
7070
/**
7171
* Card constructor.
7272
*
73-
* @param string $card_number
73+
* @param string $card_number
7474
*
7575
* @throws \LVR\CreditCard\Exceptions\CreditCardException
7676
*/
@@ -84,9 +84,9 @@ public function __construct(string $card_number = '')
8484
}
8585

8686
/**
87-
* @param string $card_number
88-
*
87+
* @param string $card_number
8988
* @return $this
89+
*
9090
* @throws \LVR\CreditCard\Exceptions\CreditCardPatternException
9191
*/
9292
public function setCardNumber(string $card_number)
@@ -106,6 +106,7 @@ public function setCardNumber(string $card_number)
106106

107107
/**
108108
* @return bool
109+
*
109110
* @throws \LVR\CreditCard\Exceptions\CreditCardChecksumException
110111
* @throws \LVR\CreditCard\Exceptions\CreditCardCharactersException
111112
* @throws \LVR\CreditCard\Exceptions\CreditCardException
@@ -164,7 +165,6 @@ public function brand()
164165

165166
/**
166167
* @param $cvc
167-
*
168168
* @return bool
169169
*/
170170
public function isValidCvc($cvc)
@@ -176,10 +176,8 @@ public function isValidCvc($cvc)
176176
/**
177177
* Check CVS length against possible lengths.
178178
*
179-
* @param string|int $cvc
180-
*
181-
* @param array $available_lengths
182-
*
179+
* @param string|int $cvc
180+
* @param array $available_lengths
183181
* @return bool
184182
*/
185183
public static function isValidCvcLength($cvc, array $available_lengths = [3, 4])

src/Cards/Mir.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,9 @@
66

77
/**
88
* Class Mir.
9+
*
910
* @link https://nspk.com/
11+
*
1012
1113
*/
1214
class Mir extends Card implements CreditCard

src/ExpirationDateValidator.php

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@ class ExpirationDateValidator
1919
/**
2020
* ExpirationDateValidator constructor.
2121
*
22-
* @param string $year
23-
* @param string $month
22+
* @param string $year
23+
* @param string $month
2424
*/
2525
public function __construct(string $year, string $month)
2626
{
@@ -29,9 +29,8 @@ public function __construct(string $year, string $month)
2929
}
3030

3131
/**
32-
* @param string $year
33-
* @param string $month
34-
*
32+
* @param string $year
33+
* @param string $month
3534
* @return mixed
3635
*/
3736
public static function validate(string $year, string $month)
@@ -51,7 +50,6 @@ public function isValid()
5150

5251
/**
5352
* @param $year
54-
*
5553
* @return $this
5654
*/
5755
protected function setYear($year)

src/Factory.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -40,9 +40,9 @@ class Factory
4040
];
4141

4242
/**
43-
* @param string|mixed $card_number
44-
*
43+
* @param string|mixed $card_number
4544
* @return \LVR\CreditCard\Cards\Card
45+
*
4646
* @throws \LVR\CreditCard\Exceptions\CreditCardException
4747
*/
4848
public static function makeFromNumber($card_number)
@@ -51,9 +51,9 @@ public static function makeFromNumber($card_number)
5151
}
5252

5353
/**
54-
* @param string|mixed $card_number
55-
*
54+
* @param string|mixed $card_number
5655
* @return mixed
56+
*
5757
* @throws \LVR\CreditCard\Exceptions\CreditCardException
5858
*/
5959
protected static function determineCardByNumber($card_number)

tests/Unit/CardCvcTest.php

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -59,10 +59,8 @@ public function it_checks_cvc_code_length()
5959
}
6060

6161
/**
62-
* @param string|int $cvc
63-
*
64-
* @param null $testCard
65-
*
62+
* @param string|int $cvc
63+
* @param null $testCard
6664
* @return mixed
6765
*/
6866
protected function validator($cvc, $testCard = null)

0 commit comments

Comments
 (0)