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

afterUpdate callback not provided the correct schema #971

Closed
wants to merge 1 commit into from
Closed

afterUpdate callback not provided the correct schema #971

wants to merge 1 commit into from

Conversation

chadxz
Copy link

@chadxz chadxz commented Apr 24, 2015

Here is a failing test for #698

var val = values[key];
if (typeof val === 'object') {
// will stringify arrays and objects
values[key] = JSON.stringify(val);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This forces the values to change type, so I think this test will always fail.

@dmarcelino
Copy link
Member

Hi @chadxz, after looking at this I don't think this is the right place/way to test this issue as in your test it forces invalid values to be passed to afterUpdate. In other words, this test would promote the wrong fix.

Please take a look at balderdashy/waterline-adapter-tests#73, I believe that's the correct way of testing this issue. The build results show this issue only happens on sails-mysql and that's where this needs to be fixed.

I'm closing this for now, please re-open if you disagree of if I missed something.

Thanks

@dmarcelino dmarcelino closed this May 16, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants