fix: rewrite condition for admin counting
All checks were successful
Update changelog / changelog (push) Successful in 25s

This commit is contained in:
2025-12-16 10:46:32 +01:00
parent defa00d0d3
commit a8f4afbfd8

View File

@@ -66,7 +66,7 @@ public class Seeder
if (userCount == 0)
Console.WriteLine("[Warn]: No user accounts found. Running a server no one can access! Consider creating an account with `Shadow addUser`.");
int adminCount = db.Users.Count(u => u.IsAdmin());
int adminCount = db.Users.Count(u => u.Role == 0); // equivalent to u.IsAdmin()
if (adminCount == 0 && userCount > 0)
Console.WriteLine("[Warn]: No admin accounts exist. Consider creating one with `Shadow addUser`.");