2 3 4
# File 'lib/viitenumero/viite_validator.rb', line 2 def validate_each(record, attribute, value) record.errors[attribute] << (options[:message] || 'on virheellinen') unless Viite.valid?(value) end