Skip to content

Commit

Permalink
Update GraphApplication.php
Browse files Browse the repository at this point in the history
  • Loading branch information
staabm committed Dec 14, 2024
1 parent 17f7be9 commit 92453a6
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion lib/GraphApplication.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,11 @@ final class GraphApplication
*/
public function start(string $jsonGlob): int
{
$jsonFiles = glob($jsonGlob);
$jsonFiles = glob($jsonGlob, GLOB_NOSORT);
usort( $jsonFiles, function( string $a, string $b ) {

Check failure on line 14 in lib/GraphApplication.php

View workflow job for this annotation

GitHub Actions / phpstan static code analysis (ubuntu-latest, 7.4)

Parameter #1 $array_arg of function usort expects TArray of array<string>, list<string>|false given.

Check failure on line 14 in lib/GraphApplication.php

View workflow job for this annotation

GitHub Actions / phpstan static code analysis (ubuntu-latest, 8.1)

Parameter #1 $array of function usort expects TArray of array<string>, list<string>|false given.
return filemtime($a) - filemtime($b);
});

if (!$jsonFiles) {
throw new \RuntimeException('No files found for ' . $jsonGlob);
}
Expand Down

0 comments on commit 92453a6

Please sign in to comment.