예제 #1
0
 public static bool IsStudent(CcValidatedToken validatedToken) => validatedToken.CcClaims.First(a => a.ClaimType == CcClaimType.UserType).Value == "Student";
예제 #2
0
 public static bool IsEducator(CcValidatedToken validatedToken) => validatedToken.CcClaims.First(a => a.ClaimType == CcClaimType.UserType).Value == "Educator";
예제 #3
0
 public static int GetEducatorId(CcValidatedToken validatedToken) => int.Parse(validatedToken.CcClaims.First(a => a.ClaimType == CcClaimType.EducatorId).Value);
예제 #4
0
 public static int GetPortfolioId(CcValidatedToken validatedToken) => int.Parse(validatedToken.CcClaims.First(a => a.ClaimType == CcClaimType.StudentPortfolioId).Value);
예제 #5
0
 public static string GetUserType(CcValidatedToken validatedToken) => validatedToken.CcClaims.First(a => a.ClaimType == CcClaimType.UserType).Value;