System.Security.Claims.ClaimsPrincipalExtensions.GetSurveyUserIdValue C# (CSharp) Method

GetSurveyUserIdValue() public static method

public static GetSurveyUserIdValue ( this principal ) : int
principal this
return int
        public static int GetSurveyUserIdValue(this ClaimsPrincipal principal)
        {
            return (int)Convert.ChangeType(principal.FindFirstValue(SurveyClaimTypes.SurveyUserIdClaimType, true), typeof(int));
        }