lib/zunnit/setup.rb in zunnit-0.3.3 vs lib/zunnit/setup.rb in zunnit-0.3.4

- old
+ new

@@ -1,11 +1,10 @@ module Zunnit extend Utils - mattr_accessor :client, :key, :version, :actions + mattr_accessor :client, :key, :version, :actions, :url # Fixed constants - URL = "http://api.zunnit.com/" ACTIONS = { :related_items => "/related/items", :recommendation_items_for_user => "/recommendation/items/for_user", :recommendation_groups_for_user => "/recommendation/groups/for_user", :recommendation_users_for_user => "/recommendation/users/for_user", @@ -19,8 +18,9 @@ } def self.setup self.actions = ACTIONS yield self if block_given? + self.url ||= "http://#{self.client}.zunnit.com/" self end end