Skip to content

Commit 65ab502

Browse files
committed
Fix preg_match calls
1 parent 111848c commit 65ab502

File tree

4 files changed

+4
-4
lines changed

4 files changed

+4
-4
lines changed

src/Action/JSLinter.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ protected function shouldSkipFileCheck(string $file, array $excludedFiles): bool
5353
foreach ($excludedFiles as $excludedFile) {
5454
// File definition using regexp
5555
if ($excludedFile[0] === '/') {
56-
if (preg_match($excludedFile, $file) !== false) {
56+
if (preg_match($excludedFile, $file) === 1) {
5757
return true;
5858
}
5959

src/Action/JSPrettier.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ protected function shouldSkipFileCheck(string $file, array $excludedFiles): bool
5353
foreach ($excludedFiles as $excludedFile) {
5454
// File definition using regexp
5555
if ($excludedFile[0] === '/') {
56-
if (preg_match($excludedFile, $file) !== false) {
56+
if (preg_match($excludedFile, $file) === 1) {
5757
return true;
5858
}
5959

src/Action/PHPCSFixer.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ protected function shouldSkipFileCheck(string $file, array $excludedFiles): bool
5050
foreach ($excludedFiles as $excludedFile) {
5151
// File definition using regexp
5252
if ($excludedFile[0] === '/') {
53-
if (preg_match($excludedFile, $file) !== false) {
53+
if (preg_match($excludedFile, $file) === 1) {
5454
return true;
5555
}
5656

src/Action/PHPStan.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ protected function shouldSkipFileCheck(string $file, array $excludedFiles): bool
5050
foreach ($excludedFiles as $excludedFile) {
5151
// File definition using regexp
5252
if ($excludedFile[0] === '/') {
53-
if (preg_match($excludedFile, $file) !== false) {
53+
if (preg_match($excludedFile, $file) === 1) {
5454
return true;
5555
}
5656

0 commit comments

Comments
 (0)