ObjectMapper.configure(MapperFeature, boolean) is deprecated as of Jackson 2.13
Closes gh-27206
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2020 the original author or authors.
|
||||
* Copyright 2002-2021 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -796,6 +796,7 @@ public class Jackson2ObjectMapperBuilder {
|
||||
module.addDeserializer((Class<T>) type, (JsonDeserializer<? extends T>) deserializer));
|
||||
}
|
||||
|
||||
@SuppressWarnings("deprecation") // on Jackson 2.13: configure(MapperFeature, boolean)
|
||||
private void configureFeature(ObjectMapper objectMapper, Object feature, boolean enabled) {
|
||||
if (feature instanceof JsonParser.Feature) {
|
||||
objectMapper.configure((JsonParser.Feature) feature, enabled);
|
||||
|
||||
Reference in New Issue
Block a user