Skip to content

Commit

Permalink
Refactor code
Browse files Browse the repository at this point in the history
  • Loading branch information
PasinduYeshan committed Oct 20, 2023
1 parent 561431f commit b85e1c4
Showing 1 changed file with 5 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -290,7 +290,7 @@ private void processBulkRequestContent(BulkRequestContent bulkRequestContent, Ma

try {
if (userIDMappings == null || userIDMappings.isEmpty() ||
method.equals(SCIMConstants.OperationalConstants.DELETE)) {
SCIMConstants.OperationalConstants.DELETE.equals(method)) {
return;
}

Expand Down Expand Up @@ -354,11 +354,10 @@ private JSONArray getUserArrayForPatch(JSONObject dataJson, String usersOrMember
if (isValidOperation(operation, usersOrMembersKey)) {
if (operation.has(SCIMConstants.OperationalConstants.PATH)) {
return operation.optJSONArray(SCIMConstants.OperationalConstants.VALUE);
} else {
JSONObject valueObject = operation.optJSONObject(SCIMConstants.OperationalConstants.VALUE);
if (valueObject != null) {
return valueObject.optJSONArray(usersOrMembersKey);
}
}
JSONObject valueObject = operation.optJSONObject(SCIMConstants.OperationalConstants.VALUE);
if (valueObject != null) {
return valueObject.optJSONArray(usersOrMembersKey);
}
}
}
Expand Down

0 comments on commit b85e1c4

Please sign in to comment.