Skip to content

Commit c936d6f

Browse files
committed
cs fix
1 parent 9ca0ad6 commit c936d6f

File tree

4 files changed

+6
-8
lines changed

4 files changed

+6
-8
lines changed

src/CardExpirationMonth.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ public function passes($attribute, $value)
4040
->isValid();
4141
} catch (\Exception $e) {
4242
return false;
43-
};
43+
}
4444
}
4545

4646
/**

src/CardExpirationYear.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ public function passes($attribute, $value)
4040
->isValid();
4141
} catch (\Exception $e) {
4242
return false;
43-
};
43+
}
4444
}
4545

4646
/**

src/Cards/Card.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -177,13 +177,13 @@ protected function checkImplementation()
177177
);
178178
}
179179

180-
if (! $this->number_length || ! is_array($this->number_length)) {
180+
if (empty($this->number_length) || ! is_array($this->number_length)) {
181181
throw new CreditCardLengthException(
182182
'Credit card number length is missing or is not an array'
183183
);
184184
}
185185

186-
if (! $this->cvc_length || ! is_array($this->cvc_length)) {
186+
if (empty($this->cvc_length) || ! is_array($this->cvc_length)) {
187187
throw new CreditCardCvcException(
188188
'Credit card cvc code length is missing or is not an array'
189189
);

tests/Unit/CardExpirationTest.php

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,13 @@
22

33
namespace LVR\CreditCard\Tests\Unit;
44

5-
use LVR\CreditCard\Cards\Card;
6-
use LVR\CreditCard\Exceptions\CreditCardExpirationDateException;
7-
use LVR\CreditCard\ExpirationDateValidator;
85
use LVR\CreditCard\Tests\TestCase;
96
use LVR\CreditCard\CardExpirationDate;
107
use LVR\CreditCard\CardExpirationYear;
118
use LVR\CreditCard\CardExpirationMonth;
129
use Illuminate\Support\Facades\Validator;
10+
use LVR\CreditCard\ExpirationDateValidator;
11+
use LVR\CreditCard\Exceptions\CreditCardExpirationDateException;
1312

1413
class CardExpirationTest extends TestCase
1514
{
@@ -144,7 +143,6 @@ public function it_throws_exception_if_year_and_month_is_empty()
144143
$this->assertFalse(ExpirationDateValidator::validate('', ''));
145144
}
146145

147-
148146
/**
149147
* @param string $year
150148
*

0 commit comments

Comments
 (0)