Class: Pippi::Checks::StripFollowedByEmpty::Documentation

Inherits:
Object
  • Object
show all
Defined in:
lib/pippi/checks/strip_followed_by_empty.rb

Instance Method Summary collapse

Instance Method Details

#descriptionObject



17
18
19
# File 'lib/pippi/checks/strip_followed_by_empty.rb', line 17

def description
  "Don't use String#strip followed by empty?; use String#blank? instead"
end

#instead_useObject



23
24
25
# File 'lib/pippi/checks/strip_followed_by_empty.rb', line 23

def instead_use
  "'   '.blank?"
end

#sampleObject



20
21
22
# File 'lib/pippi/checks/strip_followed_by_empty.rb', line 20

def sample
  "'   '.strip.empty?"
end