-
Notifications
You must be signed in to change notification settings - Fork 362
Added optional args to addError #141
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
Conversation
… custom error messages
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
typehinting
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's in ConstraintInterface.php the phpdoc here is just inheriting the interface class.
I'm working on a packagist package at the moment: https://packagist.org/packages/onlinesid/json-schema-provider It's to provide a Service Provider and a validator class for easy use from Silex. At the moment I have to use an alias (see the part that says dev-sid) because this pull request has been hanging for too long. I might need to start my own or find another fork with more activity. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Following #125 discussion the default case should be empty
The value of this keyword is called a format attribute. It MUST be a string. A format attribute can generally only validate a given set of instance types. If the type of the instance to validate is not in this set, validation for this format attribute and instance SHOULD succeed.
http://json-schema.org/latest/json-schema-validation.html#anchor105
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @Maks3w , you mean there should not be "$this->addError ..." under "default:" ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes the whole line must be eliminated. default must be empty
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just for clarify. This is not a bug in your PR. The bug already exists in the upstream code, the reason of modify the line is to prevent (supersede) a git conflict with #125
SAD :( |
I closed this because I had to add few more commits and it screwed up this PR. I've reopened another PR #142 |
My pull request #134 was done incorrectly. I've done it on my own separate branch instead of master now.