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

Issue 5190 pt1 #5206

Merged
merged 3 commits into from Nov 20, 2014
Merged

Issue 5190 pt1 #5206

merged 3 commits into from Nov 20, 2014

Conversation

markstory
Copy link
Member

Fix an annoying issue where notEmpty() callbacks would cause fatal errors as the entity would be the incorrect type.

Refs #5190

When an association is undefined return a concrete entity class. This is
necessary as notEmpty/allowEmpty callbacks could reference the entity
provider.

Refs #5190
@lorenzo
Copy link
Member

lorenzo commented Nov 19, 2014

I'm a bit reluctant to add more code around this, since the new validation code is progressing towards having to entity provider in the validator. This is a great solution for the current state of the code, though.

@markstory
Copy link
Member Author

I figure the two lines being added are unlikely to change as the context handler will still need to create empty entities when accessing non-existent association properties.

lorenzo added a commit that referenced this pull request Nov 20, 2014
@lorenzo lorenzo merged commit b7429be into 3.0 Nov 20, 2014
@lorenzo lorenzo deleted the issue-5190-pt1 branch November 20, 2014 09:39
@lorenzo
Copy link
Member

lorenzo commented Nov 20, 2014

Fair enough :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants