diff --git a/spring-data-envers/src/main/java/org/springframework/data/envers/repository/support/EnversRevisionRepositoryImpl.java b/spring-data-envers/src/main/java/org/springframework/data/envers/repository/support/EnversRevisionRepositoryImpl.java index ef55a78809..334aa60ee8 100755 --- a/spring-data-envers/src/main/java/org/springframework/data/envers/repository/support/EnversRevisionRepositoryImpl.java +++ b/spring-data-envers/src/main/java/org/springframework/data/envers/repository/support/EnversRevisionRepositoryImpl.java @@ -240,17 +240,12 @@ RevisionMetadata createRevisionMetadata() { private static RevisionMetadata.RevisionType convertRevisionType(RevisionType datum) { - switch (datum) { - - case ADD: - return INSERT; - case MOD: - return UPDATE; - case DEL: - return DELETE; - default: - return UNKNOWN; - } + return switch (datum) { + case ADD -> INSERT; + case MOD -> UPDATE; + case DEL -> DELETE; + default -> UNKNOWN; + }; } }