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

fix: fields with json type display 'null' #1051

Merged
merged 1 commit into from
Jul 27, 2023
Merged

fix: fields with json type display 'null' #1051

merged 1 commit into from
Jul 27, 2023

Conversation

joebuono
Copy link
Contributor

@joebuono joebuono commented Jul 27, 2023

Problem

In CMS, if the customer creates an empty record and then reopens the record, 'null' is displayed for JSON fields.

json-null

Solution

Adds a condition to avoid stringifying null. This change also applies to metadata and nonModelField types as well as json.

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@joebuono joebuono requested a review from a team as a code owner July 27, 2023 21:52
@codecov-commenter
Copy link

Codecov Report

Merging #1051 (b702d38) into main (694d214) will not change coverage.
The diff coverage is n/a.

❗ Your organization is not using the GitHub App Integration. As a result you may experience degraded service beginning May 15th. Please install the Github App Integration for your organization. Read more.

Impacted file tree graph

@@           Coverage Diff           @@
##             main    #1051   +/-   ##
=======================================
  Coverage   93.86%   93.86%           
=======================================
  Files         124      124           
  Lines        5790     5790           
  Branches     1747     1747           
=======================================
  Hits         5435     5435           
  Misses        337      337           
  Partials       18       18           
Files Changed Coverage Δ
...react/lib/forms/form-renderer-helper/form-state.ts 98.93% <ø> (ø)

Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 694d214...b702d38. Read the comment docs.

@joebuono joebuono merged commit 0045ee8 into main Jul 27, 2023
@joebuono joebuono deleted the fix/json-null branch July 27, 2023 23:24
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.

5 participants