Skip to content

Commit

Permalink
fix: ensure that data location url is cleared visually (#2348)
Browse files Browse the repository at this point in the history
  • Loading branch information
fboulnois authored Oct 5, 2023
1 parent f0b9404 commit 8428d33
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -524,7 +524,8 @@ export const EditConsentGroup = (props) => {
validators: [FormValidators.URL],
disabled: consentGroup.dataLocation === 'Not Determined',
placeholder: 'Enter a URL for your data location here',
defaultValue: consentGroup.url,
// React doesn't rerender this value when it is undefined, so set it to empty string
defaultValue: consentGroup.dataLocation === 'Not Determined' ? '' : consentGroup.url,
onChange,
validation: validation.url,
onValidationChange,
Expand Down

0 comments on commit 8428d33

Please sign in to comment.