faraday_middleware-aws-sigv4 0.2.1 → 0.2.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 58dcd973a56031dbf19ae5d92aedbd97e45343f5
4
- data.tar.gz: b808c8e558f9985c17b4d019d5006be6251895d2
3
+ metadata.gz: 5261b18d9aa30fdf39be58b9c030156590629001
4
+ data.tar.gz: 7e8879d43e869b8a7c72b869601d3265d9a3f0ab
5
5
  SHA512:
6
- metadata.gz: e21d7115cdc292d2fe99747c60013ae9530c903f2893952f0a6863c008db1a3609aab2d19a164c680847bfa870d3fb3403323a8d723f321a8372897332c8db3e
7
- data.tar.gz: e4b7a49e99bf7f3f391ea5c64b635a803f2550e975ec99d628c52a17e3a9c7bee73444993e30c1fdff7774f07039c350fcf57a0820b09e62a2338659d3995d4f
6
+ metadata.gz: fde65a4dbb4c7f1099b08262db7d699757e4b77bf13c5e028bcd1671b974f978c7a3da5d6bcb045aafe3d94343b9d085b10e8bc757ca78574180352bd72b0858
7
+ data.tar.gz: 9a5f8f306279fb1ee07b4ef29d214bc77ad8b07d38b0df5d9d0609fbd8eb8a93b609956d93d5c1af9defd611babc0489fc3a4303fef451299d619bf8c631a106
@@ -4,7 +4,7 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
4
 
5
5
  Gem::Specification.new do |spec|
6
6
  spec.name = 'faraday_middleware-aws-sigv4'
7
- spec.version = '0.2.1'
7
+ spec.version = '0.2.2'
8
8
  spec.authors = ['Genki Sugawara']
9
9
  spec.email = ['sugawara@cookpad.com']
10
10
 
@@ -22,22 +22,20 @@ module FaradayMiddleware::AwsSigV4Util
22
22
  end
23
23
 
24
24
  def seahorse_encode_www_form(params)
25
- params.map {|key, value|
25
+ params.flat_map {|key, value|
26
26
  encoded_key = URI.encode_www_form_component(key)
27
27
 
28
28
  if value.nil?
29
29
  encoded_key
30
- elsif value.respond_to?(:to_ary)
31
- value.to_ary.map {|v|
30
+ else
31
+ Array(value).map do |v|
32
32
  if v.nil?
33
33
  # nothing to do
34
34
  else
35
35
  encoded_key + '=' + Aws::Sigv4::Signer.uri_escape(v)
36
36
  end
37
- }.join('&')
38
- else
39
- encoded_key + '=' + Aws::Sigv4::Signer.uri_escape(value)
37
+ end
40
38
  end
41
- }.join('&')
39
+ }.join(?&)
42
40
  end
43
41
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: faraday_middleware-aws-sigv4
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Genki Sugawara