Skip to content

Commit a88a62e

Browse files
committed
Merge pull request alibaba#106 from ptma/master
属性名首字母小写但第二个字母大写的情况
2 parents 04e37a4 + d33530b commit a88a62e

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/main/java/com/alibaba/fastjson/util/TypeUtils.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1001,6 +1001,8 @@ public static List<FieldInfo> computeGetters(Class<?> clazz, Map<String, String>
10011001
propertyName = methodName.substring(4);
10021002
} else if (c3 == 'f') {
10031003
propertyName = methodName.substring(3);
1004+
} else if (methodName.length()>=5 && Character.isUpperCase(methodName.charAt(4))){
1005+
propertyName = Introspector.decapitalize(methodName.substring(3));
10041006
} else {
10051007
continue;
10061008
}

0 commit comments

Comments
 (0)