Fixed the user token issue #865

pull/1488/head
Jamie.Rees 7 years ago
parent 24e424f004
commit 0d1ee148c7

@ -61,7 +61,8 @@ namespace Ombi.Controllers
var claims = new List<Claim>
{
new Claim(JwtRegisteredClaimNames.Sub, user.UserName),
new Claim("name", user.UserName),
new Claim(ClaimTypes.NameIdentifier, user.Id),
new Claim(ClaimTypes.Name, user.UserName),
new Claim(JwtRegisteredClaimNames.Jti, Guid.NewGuid().ToString())
};
claims.AddRange(roles.Select(role => new Claim("role", role)));

Loading…
Cancel
Save