Spring mvc empty array as a default value

前端 未结 1 697
旧时难觅i
旧时难觅i 2021-01-12 14:32

I have a spring controller method that receives some optional arrays as parameters. They are not required, but I\'d like them to be not null, but just empty arrays when they

相关标签:
1条回答
  • 2021-01-12 15:25

    Found the solution. The default empty array value is just "". But the problem is that even though the parameter is not required, it throws the 400th error. Weird. Working on that.

    0 讨论(0)
提交回复
热议问题