Sha256: 41da2e4caba7e6bfab28e318d583a3ba19ae81a48910e7591c99dd98aae61ae2
Contents?: true
Size: 843 Bytes
Versions: 3
Compression:
Stored size: 843 Bytes
Contents
module Picasa module API class Base attr_reader :user_id, :authorization_header # @param [Hash] credentials # @option credentials [String] :user_id google username/email # @option credentials [String] :authorization_header header for authenticating requests def initialize(credentials = {}) if MultiXml.parser.to_s == "MultiXml::Parsers::Ox" raise StandardError, "MultiXml parser is set to :ox - picasa gem will not work with it currently, use one of: :libxml, :nokogiri, :rexml" end @user_id = credentials.fetch(:user_id) @authorization_header = credentials[:authorization_header] end def auth_header {}.tap do |header| header["Authorization"] = authorization_header if authorization_header end end end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
picasa-0.5.4 | lib/picasa/api/base.rb |
picasa-0.5.3 | lib/picasa/api/base.rb |
picasa-0.5.2 | lib/picasa/api/base.rb |