mirror of
https://gitee.com/chinabugotech/hutool.git
synced 2025-04-19 03:01:48 +08:00
fix bug
This commit is contained in:
parent
f33783ac1d
commit
eba516b7f1
@ -250,7 +250,9 @@ public class ObjectMapper {
|
||||
*/
|
||||
private static void mapFromBean(final Object bean, final JSONObject jsonObject, final Filter<MutableEntry<String, Object>> filter) {
|
||||
final CopyOptions copyOptions = InternalJSONUtil.toCopyOptions(jsonObject.getConfig());
|
||||
copyOptions.setFieldEditor((entry -> filter.accept(entry) ? entry : null));
|
||||
if(null != filter){
|
||||
copyOptions.setFieldEditor((entry -> filter.accept(entry) ? entry : null));
|
||||
}
|
||||
BeanUtil.beanToMap(bean, jsonObject, copyOptions);
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user