Skip to content

[BUG] JSON.parseObject 丢失 [] #3438

@JiakunXu

Description

@JiakunXu

问题描述

    public static void main(String[] args) {
        String aaa = "{\"file\":[{\"url\":\"http\"}]}";
        Bbb bbb = JSON.parseObject(aaa, Bbb.class);
        System.out.println(bbb);
    }

    @Data
    static class Bbb {
        String file;
    }

2.0.53 Test.Bbb(file=[{"url":"http"}])
2.0.54 Test.Bbb(file=[{"url":"http"}])
2.0.55 Test.Bbb(file={"url":"http"})
2.0.56 Test.Bbb(file={"url":"http"})

环境信息

  • 版本信息:[Fastjson2 2.0.55]

期待的正确结果

是修复了 2.0.54 之前版本存在的 bug,还是 2.0.55 之后版本产生的 bug。

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingfixed

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions