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

Add config option serialize_unknown_attributes #125

Conversation

Flixt
Copy link
Contributor

@Flixt Flixt commented Jul 28, 2022

Follow up PR for the discussion in #108.

This PR adds the possibility to configure if unknown attributes get serialized when as_json is called on a StoreModel::Model instance.

e.g. to turn of serialization of unknown attributes globally one could set

StoreModel.config.serialize_unknown_attributes = false

by default this settings is set to true to not break the existing behavior.

@DmitryTsepelev
Copy link
Owner

LGTM! Special thanks for the documentation update 🙂

@DmitryTsepelev DmitryTsepelev merged commit ca89843 into DmitryTsepelev:master Jul 31, 2022
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.

2 participants