From a4a62fa6b6f1e80c4e739f9702c59c3e13090dfc Mon Sep 17 00:00:00 2001 From: sam Date: Thu, 26 Sep 2024 02:14:58 +0200 Subject: [PATCH] fix(backend): invert unlisted member filter in RenderUserAsync --- Foxnouns.Backend/Services/UserRendererService.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Foxnouns.Backend/Services/UserRendererService.cs b/Foxnouns.Backend/Services/UserRendererService.cs index 8251611..dd266fa 100644 --- a/Foxnouns.Backend/Services/UserRendererService.cs +++ b/Foxnouns.Backend/Services/UserRendererService.cs @@ -27,7 +27,7 @@ public class UserRendererService(DatabaseContext db, MemberRendererService membe IEnumerable members = renderMembers ? await db.Members.Where(m => m.UserId == user.Id).ToListAsync(ct) : []; // Unless the user is requesting their own members AND the token can read hidden members, we filter out unlisted members. - if (!(isSelfUser && tokenCanReadHiddenMembers)) members = members.Where(m => m.Unlisted); + if (!(isSelfUser && tokenCanReadHiddenMembers)) members = members.Where(m => !m.Unlisted); var authMethods = renderAuthMethods ? await db.AuthMethods