lib/validations/validates_numericality_of.rb in validatable-1.3.2 vs lib/validations/validates_numericality_of.rb in validatable-1.3.4

- old
+ new

@@ -6,10 +6,10 @@ value = instance.send(self.attribute).to_s regex = self.only_integer ? /\A[+-]?\d+\Z/ : /^\d*\.{0,1}\d+$/ not (value =~ regex).nil? end - def message + def message(instance) super || "must be a number" end end end