Skip to content

Commit

Permalink
null check..
Browse files Browse the repository at this point in the history
  • Loading branch information
katkav committed Mar 17, 2020
1 parent 8d2fd03 commit 8949d31
Showing 1 changed file with 3 additions and 3 deletions.
Expand Up @@ -765,7 +765,7 @@ public <T extends ObjectType> SearchResultList<PrismObject<T>> searchObjects(Cla
// using clone of object query here because authorization mechanism adds additional (secuirty) filters to the (original) query
// at the end objectQuery contains additional filters as many times as the authZ mechanism is called.
// for more info see MID-6115
ObjectQuery query = origQuery.clone();
ObjectQuery query = origQuery != null ? origQuery.clone() : null;
if (query != null) {
ModelImplUtils.validatePaging(query.getPaging());
}
Expand Down Expand Up @@ -1097,7 +1097,7 @@ public <T extends ObjectType> SearchResultMetadata searchObjectsIterative(Class<

Validate.notNull(type, "Object type must not be null.");
Validate.notNull(parentResult, "Result type must not be null.");
ObjectQuery query = origQuery.clone();
ObjectQuery query = origQuery != null ? origQuery.clone() : null;
if (query != null) {
ModelImplUtils.validatePaging(query.getPaging());
}
Expand Down Expand Up @@ -1201,7 +1201,7 @@ public <T extends ObjectType> Integer countObjects(Class<T> type, ObjectQuery or
throws SchemaException, ObjectNotFoundException, ConfigurationException, SecurityViolationException, CommunicationException, ExpressionEvaluationException {

// see MID-6115
ObjectQuery query = origQuery.clone();
ObjectQuery query = origQuery != null ? origQuery.clone() : null;
OperationResult result = parentResult.createMinorSubresult(COUNT_OBJECTS);
result.addParam(OperationResult.PARAM_QUERY, query);

Expand Down

0 comments on commit 8949d31

Please sign in to comment.