class ShortURL::Services::MooURL

Public Class Methods

new() click to toggle source
Calls superclass method ShortURL::Service::new
   # File lib/shorturl/services/moourl.rb
 7 def initialize
 8   super("moourl.com")
 9 
10   @code = 302
11   @method = :get
12   @action = "/create/"
13   @field = "source"
14 end

Public Instance Methods

on_response(response) click to toggle source
   # File lib/shorturl/services/moourl.rb
16 def on_response(response)
17   "http://moourl.com/" + res["location"].match(/\?moo=/).post_match
18 end