Back-off in ResultProcessor if the result object is an instance of the target type.
We now do not attempt to convert the object if it is an instance of the declared target type. Closes #2347.
This commit is contained in:
@@ -219,6 +219,10 @@ public class ResultProcessor {
|
||||
|
||||
return new ChainingConverter(targetType, source -> {
|
||||
|
||||
if (source == null || targetType.isInstance(source)) {
|
||||
return source;
|
||||
}
|
||||
|
||||
Object intermediate = ChainingConverter.this.convert(source);
|
||||
|
||||
return intermediate == null || targetType.isInstance(intermediate) ? intermediate
|
||||
|
||||
Reference in New Issue
Block a user