Skip to content

Commit

Permalink
Lint
Browse files Browse the repository at this point in the history
  • Loading branch information
tannguyen04 authored and renovate[bot] committed Jul 5, 2024
1 parent c9ace39 commit 5cf6616
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Commands/ArtifactCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ class ArtifactCommand extends Command {
public function __construct(
ArtifactGit $gitWrapper = NULL,
Filesystem $fsFileSystem = NULL,
?string $name = NULL
?string $name = NULL,
) {
parent::__construct($name);
$this->fsFileSystem = is_null($fsFileSystem) ? new Filesystem() : $fsFileSystem;
Expand Down Expand Up @@ -760,7 +760,7 @@ protected function localExcludeEmpty(string $path, bool $strict = FALSE): bool {
}
$lines = file($filename);
if ($lines) {
$lines = array_map('trim', $lines);
$lines = array_map(trim(...), $lines);
$lines = array_filter($lines, static function ($line) : bool {
return strlen($line) > 0;
});
Expand Down
1 change: 1 addition & 0 deletions src/Traits/LogTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ public static function createLogger(string $name, OutputInterface $output, strin
OutputInterface::VERBOSITY_DEBUG => Level::Debug,
];
$verbosity = $output->getVerbosity();
// @phpstan-ignore-next-line
$level = $verbosityMapping[$verbosity] ?? Level::Debug;
$handler = new StreamHandler($logFile, $level);
$logger->pushHandler($handler);
Expand Down
1 change: 1 addition & 0 deletions src/Traits/TokenTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ trait TokenTrait {
* original string.
*/
protected function tokenProcess(string $string): ?string {
/* @phpstan-ignore-next-line */
return preg_replace_callback('/(?:\[([^\]]+)\])/', function (array $match) {
if (count($match) > 1) {
$parts = explode(':', $match[1], 2);
Expand Down

0 comments on commit 5cf6616

Please sign in to comment.