Class: UrlPrefixer
- Inherits:
-
Object
- Object
- UrlPrefixer
- Defined in:
- lib/calagator/url_prefixer.rb
Class Method Summary collapse
Class Method Details
.prefix(value) ⇒ Object
2 3 4 5 6 7 8 |
# File 'lib/calagator/url_prefixer.rb', line 2 def self.prefix(value) if value.blank? || value.include?("://") value else "http://#{value.lstrip}" end end |