Sha256: 8482d0a1744d14b6ebddf36519534ad806af5c45ce602b235b12df3a9eb6f58b

Contents?: true

Size: 387 Bytes

Versions: 2

Compression:

Stored size: 387 Bytes

Contents

class Fixnum
  def divisible_by?(first,*args)
    args += [first]
    args.each do |arg|
      return false unless Divisible.check(self, arg)
    end
    true
  end
  
  # <b>DEPRECATED:</b> Please use <tt>divisible_by?</tt> instead.
  def divisible_by(*args)
    warn "[DEPRECATION] `divisible_by` is deprecated.  Please use `divisible_by?` instead."
    divisible_by?(*args)
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
divisible-0.1.1 lib/divisible/core_ext.rb
divisible-0.1.0 lib/divisible/core_ext.rb