diff --git a/src/Coldairarrow.Api/DependencyInjection/Operator.cs b/src/Coldairarrow.Api/DependencyInjection/Operator.cs index 9c73f54..edc75d0 100644 --- a/src/Coldairarrow.Api/DependencyInjection/Operator.cs +++ b/src/Coldairarrow.Api/DependencyInjection/Operator.cs @@ -26,19 +26,9 @@ namespace Coldairarrow.Api UserId = httpContextAccessor?.HttpContext?.User.Claims .Where(x => x.Type == "userId").FirstOrDefault()?.Value; + TeamId = httpContextAccessor?.HttpContext?.User.Claims + .Where(x => x.Type == "teamId").FirstOrDefault()?.Value; - if (string.IsNullOrEmpty(UserId)) - { - string json = httpContextAccessor?.HttpContext?.User.Claims - .Where(x => x.Type == "user").FirstOrDefault()?.Value; - if (!string.IsNullOrEmpty(json)) - { - var user = Newtonsoft.Json.JsonConvert.DeserializeObject(json); - - UserId = user.Id; - TeamId = user.TeamId; - } - } } private Base_UserDTO _property;