mirror of
https://github.com/tgstation/tgstation-server.git
synced 2026-08-28 23:52:36 +01:00
RootAuthorizationManager properly checks children
Using Any<>(...) instead of FirstOrDefault<>(...) != null
This commit is contained in:
@@ -26,7 +26,7 @@ namespace TGS.Server
|
||||
//first allow admins
|
||||
var authSuccess = wp.IsInRole(WindowsBuiltInRole.Administrator);
|
||||
if(!authSuccess && contract == typeof(ITGLanding).Name)
|
||||
return InstanceAuthManagers.FirstOrDefault(x => x.CheckAccess(operationContext)) != null;
|
||||
return InstanceAuthManagers.Any(x => x.CheckAccess(operationContext));
|
||||
|
||||
var user = windowsIdent.Name;
|
||||
if (LastSeenUser != user)
|
||||
|
||||
Reference in New Issue
Block a user