Skip to content

Commit

Permalink
FRW-7467: Fixed cs
Browse files Browse the repository at this point in the history
  • Loading branch information
vol4onok committed Mar 11, 2024
1 parent a208c5c commit 7b6009a
Show file tree
Hide file tree
Showing 7 changed files with 10 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ public function check(CheckerInputDataDto $inputData): CheckerResponseDto

$devSprykerPackages = array_filter(
$sprykerPackages,
static fn (string $constraint): bool => strpos($constraint, static::DEV_PACKAGE_PREFIX) === 0
static fn (string $constraint): bool => strpos($constraint, static::DEV_PACKAGE_PREFIX) === 0,
);

return new CheckerResponseDto($this->createViolations($devSprykerPackages), $this->checkerDocUrl);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ protected function compareByMask(array $allowedPhpVersions, array $composerData)
{
return array_filter(
$allowedPhpVersions,
static fn (string $allowedVersion): bool => Semver::satisfies($allowedVersion . static::MAX_MINOR_VERSION_SUFFIX, $composerData['require']['php'])
static fn (string $allowedVersion): bool => Semver::satisfies($allowedVersion . static::MAX_MINOR_VERSION_SUFFIX, $composerData['require']['php']),
);
}

Expand All @@ -109,7 +109,7 @@ protected function compareByExactPhpVersion(array $allowedPhpVersions, array $co
{
return array_filter(
$allowedPhpVersions,
static fn (string $allowedVersion): bool => strpos($composerData['require']['php'], $allowedVersion) === 0
static fn (string $allowedVersion): bool => strpos($composerData['require']['php'], $allowedVersion) === 0,
);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ public function check(array $allowedPhpVersions, string $path): CheckerStrategyR
$phpVersion = $this->currentPhpVersion;
$validVersions = array_filter(
$allowedPhpVersions,
static fn (string $allowedVersion): bool => strpos($phpVersion, $allowedVersion) === 0 && version_compare($phpVersion, $allowedVersion, '>=')
static fn (string $allowedVersion): bool => strpos($phpVersion, $allowedVersion) === 0 && version_compare($phpVersion, $allowedVersion, '>='),
);

$violations = count($validVersions) === 0
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ protected function checkDeployFile(string $fileName, array $deployStructure, arr
static fn (string $version): bool => (bool)preg_match(
sprintf('/[^\d.]%s/', str_replace('.', '\.', $version)),
$imageTag,
)
),
);

if (count($validVersions) === 0) {
Expand Down
4 changes: 2 additions & 2 deletions src/Fetcher/CheckerFetcher.php
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ protected function filterAllowedCheckers(EvaluatorInputDataDto $inputData, array

return array_filter(
$checkers,
static fn (CheckerInterface $checker): bool => in_array($checker->getName(), $inputData->getCheckerNames(), true)
static fn (CheckerInterface $checker): bool => in_array($checker->getName(), $inputData->getCheckerNames(), true),
);
}

Expand All @@ -68,7 +68,7 @@ protected function filterExcludedCheckers(EvaluatorInputDataDto $inputData, arra
{
return array_filter(
$checkers,
static fn (CheckerInterface $checker): bool => !in_array($checker->getName(), $inputData->getExcludedCheckerNames(), true)
static fn (CheckerInterface $checker): bool => !in_array($checker->getName(), $inputData->getExcludedCheckerNames(), true),
);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ public function getSecurityFixes(): self
return new self(
array_filter(
$this->elements,
fn (UpgradeInstructionsReleaseGroup $releaseGroup): bool => $releaseGroup->isSecurity()
fn (UpgradeInstructionsReleaseGroup $releaseGroup): bool => $releaseGroup->isSecurity(),
),
);
}
Expand All @@ -109,7 +109,7 @@ public function getNonSecurityFixes(): self
return new self(
array_filter(
$this->elements,
fn (UpgradeInstructionsReleaseGroup $releaseGroup): bool => !$releaseGroup->isSecurity()
fn (UpgradeInstructionsReleaseGroup $releaseGroup): bool => !$releaseGroup->isSecurity(),
),
);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ public function getSecurityFixes(): self
return new self(
array_filter(
$this->elements,
fn (ReleaseGroupDto $releaseGroup): bool => $releaseGroup->isSecurity()
fn (ReleaseGroupDto $releaseGroup): bool => $releaseGroup->isSecurity(),
),
);
}
Expand Down

0 comments on commit 7b6009a

Please sign in to comment.