Skip to content

Commit

Permalink
Retry fixing MID-3615
Browse files Browse the repository at this point in the history
  • Loading branch information
mederly committed Jun 6, 2017
1 parent 23c1fee commit 3e14395
Showing 1 changed file with 8 additions and 6 deletions.
Expand Up @@ -89,20 +89,22 @@ public boolean match(PrismContainerValue containerValue, MatchingRuleRegistry ma

MatchingRule matching = getMatchingRuleFromRegistry(matchingRuleRegistry, item);

for (Object val : item.getValues()){
if (val instanceof PrismPropertyValue){
for (Object val : item.getValues()) {
if (val instanceof PrismPropertyValue) {
Object value = ((PrismPropertyValue) val).getValue();
Iterator<String> iterator = (Iterator<String>) toRealValues().iterator();
while(iterator.hasNext()){
for (Object o : toRealValues()) {
if (o == null) {
continue; // shouldn't occur
}
StringBuilder sb = new StringBuilder();
if (!anchorStart) {
sb.append(".*");
}
sb.append(Pattern.quote(iterator.next()));
sb.append(Pattern.quote(o.toString()));
if (!anchorEnd) {
sb.append(".*");
}
if (matching.matchRegex(value, sb.toString())){
if (matching.matchRegex(value, sb.toString())) {
return true;
}
}
Expand Down

0 comments on commit 3e14395

Please sign in to comment.