Class: Mush::Services::Unu
- Inherits:
-
Mush::Service
- Object
- Mush::Service
- Mush::Services::Unu
- Defined in:
- lib/mush/services/unu.rb
Instance Method Summary collapse
Methods inherited from Mush::Service
Instance Method Details
#shorten(url) ⇒ Object
8 9 10 11 12 13 14 |
# File 'lib/mush/services/unu.rb', line 8 def shorten(url) raise InvalidURI.new("Please provide a valid URI") if url.empty? = {} [:query] = {:url => url} get('/unu-api-simple', ).body.chomp end |