Remove uneeded lines

Rails form already add an error class when image or document attachments
has validations errors.
This commit is contained in:
Senén Rodero Rodríguez
2019-09-23 10:51:17 +02:00
parent 608e113d03
commit d1af36d1be
2 changed files with 0 additions and 2 deletions

View File

@@ -32,7 +32,6 @@ module DocumentsHelper
end
def render_attachment(builder, document)
klass = document.errors[:attachment].any? ? "error" : ""
klass = document.persisted? || document.cached_attachment.present? ? " hide" : ""
html = builder.label :attachment,
t("documents.form.attachment_label"),