shenyu icon indicating copy to clipboard operation
shenyu copied to clipboard

GsonUtils.getInstance().convertToMap() throws exception

Open ttttangzhen opened this issue 5 years ago • 1 comments

Describe the bug

when I run this unit test org.dromara.soul.plugin.dubbo.common.param.DubboBodyParamResolveServiceTest#testBuildParameterWithNull

if I set varible body with

{
  "complexBean": {
    "dubboTest": {
      "id": null,
      "name": null
    },
    "idLists": [
      null,
      null
    ],
    "idMaps": {
      "id2": null,
      "id1": null
    }
  },
  "name": null
}

the method will throws Exception because of that the json has a key idList contain null.

do you think it need to be fixed? if so, I will fix it.

ttttangzhen avatar Apr 23 '21 09:04 ttttangzhen

@ttttangzhen yes. please feel free to submit a pr.

dengliming avatar Apr 23 '21 09:04 dengliming