lib/picasa/client.rb in picasa-0.6.7 vs lib/picasa/client.rb in picasa-0.7.0
- old
+ new
@@ -62,14 +62,14 @@
end
# @return [String]
def authenticate
response = Connection.new.post(
- :host => HTTP::API_AUTH_URL,
- :headers => {"Content-Type" => "application/x-www-form-urlencoded"},
- :path => "/accounts/ClientLogin",
- :body => Utils.inline_query(
+ host: HTTP::API_AUTH_URL,
+ headers: {"Content-Type" => "application/x-www-form-urlencoded"},
+ path: "/accounts/ClientLogin",
+ body: Utils.inline_query(
"accountType" => "HOSTED_OR_GOOGLE",
"Email" => user_id,
"Passwd" => password,
"service" => "lh2",
"source" => "ruby-gem-picasa-v#{VERSION}"
@@ -85,10 +85,10 @@
def authenticates?
password && authorization_header.nil?
end
def credentials
- {:user_id => user_id}.tap do |credentials|
+ {user_id: user_id}.tap do |credentials|
credentials[:authorization_header] = authorization_header if authorization_header
end
end
def extract_auth_key(data)