]> git.openstreetmap.org Git - rails.git/blobdiff - app/validators/utf8_validator.rb
Merge remote-tracking branch 'upstream/pull/4776'
[rails.git] / app / validators / utf8_validator.rb
index dec6f4d968f2f993eb996e0b603bbf4877c995f6..0c6b3f5949e9eec7ba719aa2096a3b49fff71606 100644 (file)
@@ -2,7 +2,7 @@
 # validation method to be included like any other validations methods
 # in the models definitions. this one checks that the named attribute
 # is a valid UTF-8 format string.
-class UTF8Validator < ActiveModel::EachValidator
+class Utf8Validator < ActiveModel::EachValidator
   def validate_each(record, attribute, value)
     record.errors.add(attribute, " is invalid UTF-8") unless UTF8.valid? value
   end