Skip to content

Commit 319ea1d

Browse files
committed
Remove force setting visiblitliy for records
1 parent 3a0991c commit 319ea1d

File tree

1 file changed

+0
-8
lines changed

1 file changed

+0
-8
lines changed

src/main/java/com/fasterxml/jackson/databind/cfg/MapperConfigBase.java

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -839,14 +839,6 @@ public final VisibilityChecker<?> getDefaultVisibilityChecker(Class<?> baseType,
839839
vc = VisibilityChecker.Std.allPublicInstance();
840840
} else {
841841
vc = getDefaultVisibilityChecker();
842-
// 20-May-2023, tatu: [databind#3906] Must reset visibility for Records
843-
// to avoid hiding Constructors.
844-
if (ClassUtil.isRecordType(baseType)) {
845-
// But only if creator auto-detection enabled:
846-
if (isEnabled(MapperFeature.AUTO_DETECT_CREATORS)) {
847-
vc = vc.withCreatorVisibility(Visibility.NON_PRIVATE);
848-
}
849-
}
850842
}
851843
AnnotationIntrospector intr = getAnnotationIntrospector();
852844
if (intr != null) {

0 commit comments

Comments
 (0)