Use not deprecated method to check if a field contains errors.

This commit is contained in:
Senén Rodero Rodríguez
2017-06-26 15:17:08 +02:00
parent 3e976b4f4b
commit 7c998e541e

View File

@@ -26,7 +26,7 @@ module InvestmentsHelper
end
def errors_on_image(investment)
investment.errors[:image].join(', ') if investment.errors.has_key?(:image)
investment.errors[:image].join(', ') if investment.errors.key?(:image)
end
end