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

Preserve empty JSON types #81

Merged
merged 4 commits into from
Jun 7, 2019
Merged

Preserve empty JSON types #81

merged 4 commits into from
Jun 7, 2019

Commits on Jun 7, 2019

  1. Configuration menu
    Copy the full SHA
    70c9012 View commit details
    Browse the repository at this point in the history
  2. Preserve empty JSON types

    The existing behavior when specifying `serializer: :json` was to store
    and return an empty Hash (`{}`) for null or empty values, including
    empty arrays.
    
    This changes the encode logic to store the JSON representation of
    any given value. During decode, any valid JSON string can be decoded. We
    special case `nil` or `""` (empty string) to return `nil` (instead of
    `{}` previously).
    
    This could be a breaking for applications that depend on the empty hash
    == nil behavior.
    justincampbell committed Jun 7, 2019
    Configuration menu
    Copy the full SHA
    2761d31 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    6741042 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    f45e70c View commit details
    Browse the repository at this point in the history