File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed
src/main/java/tools/jackson/databind/deser Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change 2424import tools .jackson .databind .ext .jdk8 .OptionalLongDeserializer ;
2525import tools .jackson .databind .introspect .*;
2626import tools .jackson .databind .jsontype .TypeDeserializer ;
27+ import tools .jackson .databind .jsontype .impl .NoOpTypeDeserializer ;
2728import tools .jackson .databind .type .*;
2829import tools .jackson .databind .util .*;
2930
@@ -767,8 +768,12 @@ public ValueDeserializer<?> createCollectionDeserializer(DeserializationContext
767768
768769 // Then optional type info: if type has been resolved, we may already know type deserializer:
769770 TypeDeserializer contentTypeDeser = (TypeDeserializer ) contentType .getTypeHandler ();
770- // but if not, may still be possible to find:
771- if (contentTypeDeser == null ) {
771+ // [databind#1654]: @JsonTypeInfo(use = Id.NONE) should not apply type deserializer
772+ // when custom content deserializer is specified via @JsonDeserialize(contentUsing = ...)
773+ if (contentTypeDeser instanceof NoOpTypeDeserializer ) {
774+ contentTypeDeser = null ;
775+ } else if (contentTypeDeser == null ) {
776+ // but if not, may still be possible to find:
772777 contentTypeDeser = ctxt .findTypeDeserializer (contentType );
773778 }
774779 // 23-Nov-2010, tatu: Custom deserializer?
You can’t perform that action at this time.
0 commit comments