Skip to content

Commit 4595c81

Browse files
committed
add download sort to summary page
1 parent 8ec3dad commit 4595c81

1 file changed

Lines changed: 5 additions & 3 deletions

File tree

src/PackageRegistryService/Pages/Components/PackageSummary.cs

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -43,11 +43,13 @@ public static string RenderList(IEnumerable<PackageSummary> summaries)
4343
{
4444
var testPackages =
4545
summaries
46-
.Where(p => p.Name.Contains("test"));
47-
46+
.Where(p => p.Name.Contains("test"))
47+
.OrderByDescending(p => p.TotalDownloads);
48+
4849
var prodPackages =
4950
summaries
50-
.Where(p => !p.Name.Contains("test"));
51+
.Where(p => !p.Name.Contains("test"))
52+
.OrderByDescending(p => p.TotalDownloads);
5153

5254
var testContent = PackageSummary.RenderTable("Test Packages", "These packages are used primarily to internally test validation pipelines.", testPackages);
5355
var prodContent = PackageSummary.RenderTable("Available Validation Packages", "These packages are intended to be used in ARC validation pipelines.", prodPackages);

0 commit comments

Comments
 (0)