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