hellosign-ruby-sdk 3.0.2 → 3.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -103,6 +103,7 @@ module HelloSign
103
103
  private
104
104
 
105
105
  def request(path, method, options={})
106
+ strip_options_whitespace(options)
106
107
  make_connection(options).send method do |request|
107
108
  if options[:oauth_request]
108
109
  request.url "#{path}", options[:params]
@@ -191,6 +192,19 @@ module HelloSign
191
192
  prepare opts, :ccs
192
193
  end
193
194
 
195
+ def strip_options_whitespace(hash)
196
+ hash.each do |k, v|
197
+ case v
198
+ when String
199
+ v.strip!
200
+ when Array
201
+ v.each {|av| av.strip!}
202
+ when Hash
203
+ strip_options_whitespace(v)
204
+ end
205
+ end
206
+ end
207
+
194
208
  def prepare opts, key
195
209
  return unless opts[key]
196
210
  opts[key].each_with_index do |value, index|
@@ -1,3 +1,3 @@
1
1
  module HelloSign
2
- VERSION = "3.0.2"
2
+ VERSION = "3.0.3"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: hellosign-ruby-sdk
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.2
4
+ version: 3.0.3
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2014-05-23 00:00:00.000000000 Z
12
+ date: 2014-07-10 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: bundler