We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 3c37fc1 commit fc404d6Copy full SHA for fc404d6
.travis.yml
@@ -1,6 +1,9 @@
1
language: php
2
php:
3
- 7.1
4
+ - 7.2
5
+ - 7.3
6
+ - 7.4
7
8
before_script:
9
- travis_retry composer self-update
composer.json
@@ -9,7 +9,7 @@
}
10
],
11
"require": {
12
- "php" : ">=5.6 "
+ "php" : ">=7.1"
13
},
14
"require-dev": {
15
"phpunit/phpunit": "5.5.*"
src/CPF.php
@@ -98,10 +98,10 @@ private function validateDigits ($cpf)
98
for ($t = 9; $t < 11; $t++) {
99
100
for ($d = 0, $c = 0; $c < $t; $c++) {
101
- $d += $cpf{$c} * (($t + 1) - $c);
+ $d += $cpf[$c] * (($t + 1) - $c);
102
103
$d = ((10 * $d) % 11) % 10;
104
- if ($cpf{$c} != $d) {
+ if ($cpf[$c] != $d) {
105
return false;
106
107
0 commit comments