Skip to content

Commit

Permalink
Merge d69ccba into 69d1fe9
Browse files Browse the repository at this point in the history
  • Loading branch information
kaladay committed Jan 31, 2022
2 parents 69d1fe9 + d69ccba commit 7f66a91
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ public ApiResponse assume(@RequestParam() Map<String, String> params) throws Exc
claims.put("tdl-givenname", info.get("first_name"));
claims.put("tdl-mail", info.get("tamu_preferred_alias"));

String affiliation = info.get("employee_type_name");
String affiliation = info.getOrDefault("employee_type_name", "");

if ("".equals(affiliation) || "Student".equals(affiliation)) {
String classification = info.get("classification_name").split(" ")[0].replace(",", "");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ public Credentials(Claims claims) {
this.exp = String.valueOf(claims.get("exp"));
this.email = String.valueOf(claims.get("email"));
this.role = String.valueOf(claims.get("role"));
this.affiliation = String.valueOf(claims.get("affiliation"));
this.affiliation = String.valueOf(claims.getOrDefault("affiliation", ""));
claims.entrySet().forEach(entry -> {
this.allCredentials.put(entry.getKey(), String.valueOf(entry.getValue()));
});
Expand All @@ -70,7 +70,7 @@ public Credentials(Map<String, Object> claims) {
this.exp = String.valueOf(claims.get("exp"));
this.email = String.valueOf(claims.get("email"));
this.role = String.valueOf(claims.get("role"));
this.affiliation = String.valueOf(claims.get("affiliation"));
this.affiliation = String.valueOf(claims.getOrDefault("affiliation", ""));
claims.entrySet().forEach(entry -> {
this.allCredentials.put(entry.getKey(), String.valueOf(entry.getValue()));
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ public Credentials buildAnonymousCredentials() {
}

public abstract U updateUserByCredentials(Credentials credentials);

public abstract String getAnonymousRole();

}

0 comments on commit 7f66a91

Please sign in to comment.