Skip to content

Commit e5dd6b9

Browse files
committed
Fix issues detected by psalm
1 parent 83f0b7a commit e5dd6b9

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/JsonRepositoryWriter.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
*/
2020
class JsonRepositoryWriter
2121
{
22-
private const JSON_FLAGS = JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE;
22+
private const int JSON_FLAGS = JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE;
2323

2424
private string $baseDir;
2525

@@ -144,7 +144,7 @@ private function processTool(ToolInterface $tool): ?array
144144
}
145145
$data['tools'][$name][] = $serialized;
146146
}
147-
if (empty($data['tools'])) {
147+
if (!(bool) $data['tools']) {
148148
return null;
149149
}
150150

src/SourceProvider/Tool/ToolVersionFilter.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@
99

1010
final class ToolVersionFilter
1111
{
12-
public const WILDCARD_CONSTRAINT = '*';
13-
public const NEVER_MATCHING_CONSTRAINT = '>0 <0';
12+
public const string WILDCARD_CONSTRAINT = '*';
13+
public const string NEVER_MATCHING_CONSTRAINT = '>0 <0';
1414

1515
private string $toolName;
1616
private string $allowedVersions;

0 commit comments

Comments
 (0)