hiranthaR/Json-to-Dart-Model

Error when Class name given is same as one of the generated classes

Closed this issue · 1 comments

Describe the bug
If let us say we provide class name as User and if our json looks like:

{
  "User": [
    {
      "Id": "N/A",
      "Cart": [
        "N/A"
      ]
    }
  ]
}

The class generated then contains syntax errors.

Expected behavior
An error or some kind of prefix in nested classes name having the exact same names.

@apgapg It has been corrected for the next update ;)