mirror of
https://github.com/tgstation/tgstation-server.git
synced 2026-08-23 04:57:17 +01:00
Temporary workaround for IAuthenticationContext still being a thing
This commit is contained in:
@@ -758,10 +758,16 @@ namespace Tgstation.Server.Host.Authority
|
||||
InstanceManagerRights = model.PermissionSet?.InstanceManagerRights ?? InstanceManagerRights.None,
|
||||
};
|
||||
|
||||
/*
|
||||
var currentUser = new User
|
||||
{
|
||||
Id = claimsPrincipalAccessor.User.GetTgsUserId(),
|
||||
};
|
||||
*/
|
||||
|
||||
// Temporary workaround while we work to remove authentication context
|
||||
var currentUser = DatabaseContext.Users.Local.First(
|
||||
user => user.Id == claimsPrincipalAccessor.User.GetTgsUserId());
|
||||
|
||||
DatabaseContext.Users.Attach(currentUser);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user