lib/restful_resource/base.rb in restful_resource-0.8.0 vs lib/restful_resource/base.rb in restful_resource-0.8.1

- old
+ new

@@ -5,10 +5,14 @@ def self.http=(http) @@http = http end def self.http - @@http ||= RestfulResource::HttpClient.new() + @@http ||= RestfulResource::HttpClient.new(authorization: @base_authorization) + end + + def self.http_authorization(user, password) + @base_authorization = RestfulResource::Authorization.http_authorization(user, password) end def self.base_url=(url) @base_url = URI.parse(url) end