Skip to content

Commit

Permalink
Replace deprecated method (#8351)
Browse files Browse the repository at this point in the history
Signed-off-by: Gabriel Fukushima <gabrielfukushima@gmail.com>
  • Loading branch information
gfukushima authored Jun 3, 2024
1 parent 7711367 commit 670fca6
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ private static <T> Optional<T> getAttributeFromParser(
while (!parser.isClosed()) {
final JsonToken jsonToken = parser.nextToken();
if (JsonToken.FIELD_NAME.equals(jsonToken)) {
final String currentFieldName = parser.getCurrentName();
final String currentFieldName = parser.currentName();
if (currentFieldName.equals(fieldName)) {
if (path.length == i + 1) {
parser.nextToken();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ public Map<TKey, TValue> deserialize(final JsonParser p) throws IOException {
t = p.nextToken();
}
for (; t == JsonToken.FIELD_NAME; t = p.nextToken()) {
final String fieldName = p.getCurrentName();
final String fieldName = p.currentName();
p.nextToken();
final TValue fieldValue = valueType.deserialize(p);
result.put(keyType.deserializeFromString(fieldName), fieldValue);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ public TObject deserialize(final JsonParser p) throws IOException {
}
final Set<String> presentFields = new HashSet<>();
for (; t == JsonToken.FIELD_NAME; t = p.nextToken()) {
String fieldName = p.getCurrentName();
String fieldName = p.currentName();
p.nextToken();
final DeserializableFieldDefinition<TObject, TBuilder> fieldDefinition =
deserializableFields.get(fieldName);
Expand Down

0 comments on commit 670fca6

Please sign in to comment.