Module: Fintecture::Faraday::DisabledEncoder
- Extended by:
- Forwardable
- Defined in:
- lib/fintecture/faraday/authentication/connection.rb
Class Attribute Summary collapse
-
.sort_params ⇒ Object
Returns the value of attribute sort_params.
Class Method Summary collapse
Class Attribute Details
.sort_params ⇒ Object
Returns the value of attribute sort_params.
133 134 135 |
# File 'lib/fintecture/faraday/authentication/connection.rb', line 133 def sort_params @sort_params end |
Class Method Details
.encode(params) ⇒ Object
115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 |
# File 'lib/fintecture/faraday/authentication/connection.rb', line 115 def self.encode(params) return nil if params.nil? newParams = {} params.each do |key, value| if value.instance_of?(Hash) value.each do |subkey, subvalue| newParams["#{key}[#{subkey}]"] = subvalue end else newParams[key] = value end end newParams.map { |key, value| "#{key}=#{value}" }.join('&').to_s end |