Class: String
- Inherits:
-
Object
- Object
- String
- Defined in:
- lib/news_scraper/active_support_lite/string.rb
Instance Method Summary collapse
Instance Method Details
#squish ⇒ Object
2 3 4 |
# File 'lib/news_scraper/active_support_lite/string.rb', line 2 def squish dup.squish! end |
#squish! ⇒ Object
6 7 8 9 10 |
# File 'lib/news_scraper/active_support_lite/string.rb', line 6 def squish! gsub!(/[[:space:]]+/, ' ') strip! self end |