Method: CF::UAA::Util.encode_form
- Defined in:
- lib/uaa/util.rb
.encode_form(obj) ⇒ Object
Note:
that ruby 1.9.3 converts form components to utf-8. Ruby 1.8.7 users must ensure all data is in utf-8 format before passing to form encode.
Encode an object into x-www-form-urlencoded string suitable for oauth2.
138 139 140 |
# File 'lib/uaa/util.rb', line 138 def self.encode_form(obj) obj.map {|k, v| encode_component(k) << '=' << encode_component(v)}.join('&') end |