diff --git a/app/models/dialog_import_validator.rb b/app/models/dialog_import_validator.rb index 46da9a51ef9..ede7bfda5fa 100644 --- a/app/models/dialog_import_validator.rb +++ b/app/models/dialog_import_validator.rb @@ -57,7 +57,7 @@ def check_dialog_fields_for_validity(dialog_fields) def check_dialog_associations_for_validity(dialog_fields) associations = {} - dialog_fields.each { |df| associations.merge!(df["name"] => df["dialog_field_responders"]) unless df["dialog_field_responders"].nil? } + dialog_fields.each { |df| associations.merge!(df["name"] => df["dialog_field_responders"]) if df["dialog_field_responders"].present? } unless associations.blank? circular_references = @dialog_field_association_validator.circular_references(associations) raise DialogFieldAssociationCircularReferenceError, circular_references if circular_references