[Rails-core] [Feature request] ActiveModel::Validations::NumericalityValidator multiple_of? integration

2014-09-17 Thread Matteo Panara
Why not? module ActiveModel module Validations class NumericalityValidator EachValidator CHECKS = { greater_than: :, greater_than_or_equal_to: :=, equal_to: :==, less_than: :, less_than_or_equal_to: :=, multiple_of: :multiple_of?, odd: :odd?, even:

Re: [Rails-core] [Feature request] ActiveModel::Validations::NumericalityValidator multiple_of? integration

2014-09-17 Thread Mohamed Wael Khobalatte
Where did that method come from? All other methods are Ruby methods. On Wed, Sep 17, 2014 at 3:09 PM, Matteo Panara matteo.pan...@gmail.com wrote: Why not? module ActiveModel module Validations class NumericalityValidator EachValidator CHECKS = { greater_than: :,

Re: [Rails-core] [Feature request] ActiveModel::Validations::NumericalityValidator multiple_of? integration

2014-09-17 Thread Matteo Panara
Il giorno mercoledì 17 settembre 2014 16:33:31 UTC+2, Mohamed Wael Khobalatte ha scritto: Where did that method come from? All other methods are Ruby methods. Sorry, I've seen only now that it is an ActiveSupport extension of Integer. # File

Re: [Rails-core] [Feature request] ActiveModel::Validations::NumericalityValidator multiple_of? integration

2014-09-17 Thread Matt Jones
On Sep 17, 2014, at 9:09 AM, Matteo Panara matteo.pan...@gmail.com wrote: Why not? module ActiveModel module Validations class NumericalityValidator EachValidator CHECKS = { greater_than: :, greater_than_or_equal_to: :=, equal_to: :==, less_than: :,

Re: [Rails-core] [Feature request] ActiveModel::Validations::NumericalityValidator multiple_of? integration

2014-09-17 Thread Matteo Panara
Il giorno mercoledì 17 settembre 2014 17:44:31 UTC+2, Matt jones ha scritto: multiple_of isn’t a supported option for NumericalityValidator because the method only exists for integers. Here’s some previous discussion of this situation: https://github.com/rails/rails/pull/7216 (on why