Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error message in the proper order #98

Open
RaghavendhraK opened this issue Feb 26, 2015 · 0 comments
Open

Error message in the proper order #98

RaghavendhraK opened this issue Feb 26, 2015 · 0 comments

Comments

@RaghavendhraK
Copy link

{
    "type": "object",
    "properties": {
        "customer": {
             "type": "object",
             "properties": {
                "name": {
                     "type": "string",
                     "required": true
                  }
             }
        },
        "user": {
            "type": "object",
            "properties":{
                "name": {
                    "type": "string",
                    "required": true
                }
            }
        }
    }
}

and if I provided the value like

{
    "customer": {  },
    "user": {  }
}

Then I get the error like

{
    "errors": [
        {
            "attribute": "required",
            "property": "user.name",
            "expected": true,
            "message": "is required"
        },
        {
            "attribute": "required",
            "property": "customer.name",
            "expected": true,
            "message": "is required"
        }
    ]
}

That is the order of the error message is wrong. I need to get customer and then user.

RaghavendhraK added a commit to RaghavendhraK/revalidator that referenced this issue Feb 26, 2015
4kochi pushed a commit to litixsoft/lx-valid that referenced this issue Feb 27, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant