From da5671863addd5dee08fa39c36b796eb6f3637de Mon Sep 17 00:00:00 2001 From: jvyden Date: Sat, 22 Jan 2022 21:48:16 -0500 Subject: [PATCH] Revert "Order users list by status then by user id desc" This reverts commit 75ad64db40d2d59b7006ea7ab34918f5a61cd304. --- ProjectLighthouse/Pages/UsersPage.cshtml.cs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/ProjectLighthouse/Pages/UsersPage.cshtml.cs b/ProjectLighthouse/Pages/UsersPage.cshtml.cs index cc456e13..d5125384 100644 --- a/ProjectLighthouse/Pages/UsersPage.cshtml.cs +++ b/ProjectLighthouse/Pages/UsersPage.cshtml.cs @@ -8,6 +8,7 @@ using LBPUnion.ProjectLighthouse.Pages.Layouts; using LBPUnion.ProjectLighthouse.Types; using LBPUnion.ProjectLighthouse.Types.Settings; using Microsoft.AspNetCore.Mvc; +using Microsoft.EntityFrameworkCore; namespace LBPUnion.ProjectLighthouse.Pages; @@ -35,11 +36,9 @@ public class UsersPage : BaseLayout this.Users = await this.Database.Users.Where (u => !u.Banned) + .OrderByDescending(b => b.UserId) .Skip(pageNumber * ServerStatics.PageSize) .Take(ServerStatics.PageSize) - .ToAsyncEnumerable() - .OrderBy(u => u.Status) - .ThenByDescending(u => u.UserId) .ToListAsync(); return this.Page();