Class: Object
- Inherits:
- BasicObject
- Defined in:
- lib/helpers/lib/common.rb
Instance Method Summary collapse
Instance Method Details
#blank? ⇒ Boolean
3 4 5 |
# File 'lib/helpers/lib/common.rb', line 3 def blank? respond_to?(:empty?) ? !!empty? : !self end |
#presence ⇒ Object
7 8 9 |
# File 'lib/helpers/lib/common.rb', line 7 def presence blank? ? nil : self end |
#present? ⇒ Boolean
11 12 13 |
# File 'lib/helpers/lib/common.rb', line 11 def present? !blank? end |