Skip to content

Commit

Permalink
Add role definition for getSession
Browse files Browse the repository at this point in the history
  • Loading branch information
yamelsenih committed Oct 24, 2019
1 parent 5b7dcae commit 7661fd8
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -796,6 +796,9 @@ private Session.Builder getSessionInfo(SessionRequest request) {
builder.setUuid(validateNull(session.getUUID()));
builder.setName(validateNull(session.getDescription()));
builder.setUserInfo(convertUserInfo(MUser.get(context, session.getCreatedBy())).build());
// Set role
Role.Builder roleBuilder = convertRole(MRole.get(context, session.getAD_Role_ID()), true);
builder.setRole(roleBuilder.build());
// Set default context
context.entrySet().stream()
.filter(keyValue -> String.valueOf(keyValue.getKey()).startsWith("#") || String.valueOf(keyValue.getKey()).startsWith("$"))
Expand Down

0 comments on commit 7661fd8

Please sign in to comment.