Sha256: b397bb4b20ed4168c74fc7ae4d10ccf733062506b7378d41956dd841e1a8fdd0
Contents?: true
Size: 305 Bytes
Versions: 3
Compression:
Stored size: 305 Bytes
Contents
class TrueClass def to_i 1 end end class FalseClass def to_i 0 end end class Object def to_bool ![false, 'false', '0', 0, 'f', nil, ''].include?(self.respond_to?(:downcase) ? self.downcase : self) end end class Date def tomorrow? self.to_date == ::Date.tomorrow end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
ab_admin-0.11.0 | lib/ab_admin/core_ext/other.rb |
ab_admin-0.10.0 | lib/ab_admin/core_ext/other.rb |
ab_admin-0.9.0 | lib/ab_admin/core_ext/other.rb |