making signed attributes public so that it can be used with 3rd party http request libraries to use oauth through query string

This commit is contained in:
Mike Emery 2010-11-10 15:23:48 -08:00 committed by Erik Michaels-Ober
parent e66291245d
commit c775850614

View file

@ -67,15 +67,15 @@ module SimpleOAuth
valid
end
def signed_attributes
attributes.merge(:oauth_signature => signature)
end
private
def normalized_attributes
signed_attributes.sort_by{|k,v| k.to_s }.map{|k,v| %(#{k}="#{self.class.encode(v)}") }.join(', ')
end
def signed_attributes
attributes.merge(:oauth_signature => signature)
end
def attributes
ATTRIBUTE_KEYS.inject({}){|a,k| options.key?(k) ? a.merge(:"oauth_#{k}" => options[k]) : a }
end