Skip to content

Commit

Permalink
update stan
Browse files Browse the repository at this point in the history
  • Loading branch information
LordSimal committed Aug 8, 2024
1 parent 4b2090c commit 44266ad
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 10 deletions.
4 changes: 2 additions & 2 deletions .phive/phars.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
<phive xmlns="https://phar.io/phive">
<phar name="phpstan" version="1.10.56" installed="1.10.56" location="./tools/phpstan" copy="false"/>
<phar name="psalm" version="5.20.0" installed="5.20.0" location="./tools/psalm" copy="false"/>
<phar name="phpstan" version="1.11.9" installed="1.11.9" location="./tools/phpstan" copy="false"/>
<phar name="psalm" version="5.25.0" installed="5.25.0" location="./tools/psalm" copy="false"/>
</phive>
6 changes: 4 additions & 2 deletions phpstan.neon
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,11 @@ includes:

parameters:
level: 7
checkMissingIterableValueType: false
checkGenericClassInNonGenericObjectType: false
paths:
- src/
bootstrapFiles:
- tests/bootstrap.php
ignoreErrors:
- identifier: missingType.iterableValue
- identifier: missingType.generics

3 changes: 0 additions & 3 deletions psalm-baseline.xml
Original file line number Diff line number Diff line change
Expand Up @@ -152,8 +152,5 @@
<code><![CDATA[$this->regexpParseColumn]]></code>
<code><![CDATA[$this->regexpParseField]]></code>
</ArgumentTypeCoercion>
<TypeDoesNotContainType>
<code>empty($indexes[$indexName])</code>
</TypeDoesNotContainType>
</file>
</files>
3 changes: 2 additions & 1 deletion src/Command/MigrationsCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ public static function defaultName(): string
/**
* Array of arguments to run the shell with.
*
* @var array<string>
* @var list<string>
*/
public array $argv = [];

Expand Down Expand Up @@ -198,6 +198,7 @@ public function run(array $argv, ConsoleIo $io): ?int
$name = explode(' ', $name);

array_unshift($argv, ...$name);
/** @var list<string> $argv */
$this->argv = $argv;

return parent::run($argv, $io);
Expand Down
8 changes: 6 additions & 2 deletions src/Db/Adapter/SqliteAdapter.php
Original file line number Diff line number Diff line change
Expand Up @@ -1098,8 +1098,12 @@ protected function calculateNewTableColumns(string $tableName, string|false $col
}
}

$selectColumns = array_filter($selectColumns, 'strlen');
$writeColumns = array_filter($writeColumns, 'strlen');
$selectColumns = array_filter($selectColumns, function ($value) {
return strlen($value) > 0;
});
$writeColumns = array_filter($writeColumns, function ($value) {
return strlen($value) > 0;
});
$selectColumns = array_map([$this, 'quoteColumnName'], $selectColumns);
$writeColumns = array_map([$this, 'quoteColumnName'], $writeColumns);

Expand Down

0 comments on commit 44266ad

Please sign in to comment.