Sha256: c73b84fd59a5b466be69fbd3acf6bb3b36368be1075d30c00a80dfdc63fed76c
Contents?: true
Size: 291 Bytes
Versions: 8
Compression:
Stored size: 291 Bytes
Contents
class Object def blank? respond_to?(:empty?) ? !!empty? : !self end def present? !blank? end end class String def convert_to_cents (self.to_f * 100).to_i end end class Hash def deep_compact delete_if {|k,v| v.deep_compact if v.is_a?(Hash); v.nil?} end end
Version data entries
8 entries across 8 versions & 1 rubygems