Class: Object

Inherits:
BasicObject
Defined in:
lib/active_resource/to_query.rb

Instance Method Summary collapse

Instance Method Details

#to_query(key) ⇒ Object


5
6
7
8
# File 'lib/active_resource/to_query.rb', line 5

def to_query(key)
  require 'cgi' unless defined?(CGI) && defined?(CGI::escape)
  "#{CGI.escape(key.to_param)}=#{CGI.escape(to_param.to_s)}"
end