Skip to content

Sort complexity results before encoding so that graph is properly populated #1082

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 8 commits into from
Jul 29, 2025
Next Next commit
Sort complexity results before encoding so that graph is properly pop…
…ulated
  • Loading branch information
manticorp committed Jul 23, 2025
commit ee53f8dece9d7e8a40a30352764cc88d0e15f981
2 changes: 2 additions & 0 deletions src/Report/Html/Renderer/Dashboard.php
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,8 @@ private function complexity(array $classes, string $baseLink): array
];
}

usort($result['class'], fn($a, $b) => intval($a[0] - $b[0]));

$class = json_encode($result['class']);

assert($class !== false);
Expand Down