Skip to content
This repository was archived by the owner on Sep 24, 2018. It is now read-only.

Conversation

@adamsilverstein
Copy link

Fixes an issues with the JS CLient that prevented saving a created post. Receiving and then sending the null/empty values back to the server fails a validation test, and the save fails. This change strips empty values from the return.

Fixes an issues with the JS CLient that prevents saving a created post because sending the null/empty valuesback to the server fails a validation test.
@adamsilverstein
Copy link
Author

For more details about the reasoning behind this PR, see #2303.

@danielbachhuber
Copy link
Member

I don't think we should be stripping data from the response.

What if we set any date field to null if it equals 0000 in the database, and accept a create or update request with a null date to mean to set the date value to 000 in the database?

@danielbachhuber
Copy link
Member

For slugs, the problem needs to be addressed with #1585

@kadamwhite
Copy link
Contributor

Depends on resolution of #2657, there are some differences of opinion there

@kadamwhite
Copy link
Contributor

Per #2657 we should not omit values from the data returned to the client; missing data should be exposed as null. Closing this PR and opening a new issue to track making the change Daniel suggested above.

@kadamwhite kadamwhite closed this Sep 13, 2016
@kadamwhite kadamwhite deleted the fixes/dont-return-null-or-blank-values branch September 13, 2016 22:59
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants