Commit 045a336159fdf8d24caf5b56432fe9b6538e56a1

Authored by xingyu4j
1 parent 129f9175

fix: JsonGenerator getCurrentValue 已过期

yudao-framework/yudao-spring-boot-starter-web/src/main/java/cn/iocoder/yudao/framework/desensitize/core/base/serializer/StringDesensitizeSerializer.java
@@ -84,7 +84,7 @@ public class StringDesensitizeSerializer extends StdSerializer<String> implement @@ -84,7 +84,7 @@ public class StringDesensitizeSerializer extends StdSerializer<String> implement
84 */ 84 */
85 private Field getField(JsonGenerator generator) { 85 private Field getField(JsonGenerator generator) {
86 String currentName = generator.getOutputContext().getCurrentName(); 86 String currentName = generator.getOutputContext().getCurrentName();
87 - Object currentValue = generator.getCurrentValue(); 87 + Object currentValue = generator.currentValue();
88 Class<?> currentValueClass = currentValue.getClass(); 88 Class<?> currentValueClass = currentValue.getClass();
89 return ReflectUtil.getField(currentValueClass, currentName); 89 return ReflectUtil.getField(currentValueClass, currentName);
90 } 90 }