Skip to content

Commit

Permalink
Fix isAlertVisible calculation
Browse files Browse the repository at this point in the history
  • Loading branch information
kowczarz committed Jan 12, 2024
1 parent 9255d6f commit 4e3c050
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/components/Form/FormWrapper.js
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ function FormWrapper(props) {
{isSubmitButtonVisible && (
<FormAlertWithSubmitButton
buttonText={submitButtonText}
isAlertVisible={(_.size(errors) > 0 || Boolean(errorMessage) || !_.isEmpty(formState.errorFields)) && !shouldHideFixErrorsAlert}
isAlertVisible={((_.size(errors) > 0 || !_.isEmpty(formState.errorFields)) && !shouldHideFixErrorsAlert) || Boolean(errorMessage)}
isLoading={formState.isLoading}
message={_.isEmpty(formState.errorFields) ? errorMessage : null}
onSubmit={onSubmit}
Expand Down

0 comments on commit 4e3c050

Please sign in to comment.