Skip to content

Commit

Permalink
Mutations.
Browse files Browse the repository at this point in the history
  • Loading branch information
knighto82 committed Jan 13, 2025
1 parent 0ae38a5 commit 8e16938
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,13 @@ public static Map<String, Object> initializeMap() {
}

public static Set<String> getFieldNames(Set<String> exclusions, Class<?> resourceClass) {
Set<String> mutated = new HashSet<>(exclusions);
if (null != resourceClass) {
exclusions.addAll(Arrays.stream(resourceClass.getDeclaredFields())
mutated.addAll(Arrays.stream(resourceClass.getDeclaredFields())
.map(Field::getName)
.filter(n -> !"this$0".equals(n))
.collect(Collectors.toSet()));
}
return exclusions;
return mutated;
}
}

0 comments on commit 8e16938

Please sign in to comment.