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

[BUGFIX] Rework Warning Logic #538

Merged
merged 3 commits into from
Sep 18, 2017
Merged

[BUGFIX] Rework Warning Logic #538

merged 3 commits into from
Sep 18, 2017

Conversation

offirgolan
Copy link
Collaborator

Resolves #527.

The logic for the warning message implementation was incorrect. This PR fixes that by removing the isWarning flag and computing the warningMessage / message logic via the Result update method.

Because there is now no flag to determine if a result is a warning or an error, I had to create a WarningResultCollection class which extends the ResultCollection class but reroutes all errors to warnings which solves the case of belongs-to, has-many, and alias.

Tasks:

  • Added test case(s)
  • Updated documentation

@offirgolan offirgolan merged commit bd847e6 into master Sep 18, 2017
@offirgolan offirgolan deleted the bugfix/warning-messages branch September 18, 2017 18:34
@zidjian257
Copy link

thanks for the fix - solves our issues mentioned in #537

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

Successfully merging this pull request may close these issues.

warnings are not filled on the validations object
2 participants