stripe 1.56.0 → 1.56.1

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 3b273184e3b48184ef5e176b93ffdb3718a6a14d
4
- data.tar.gz: 87924962ce71917ba07bba6c569ebbf1094460c8
3
+ metadata.gz: 7d9f405c4db8edc9240894eb3099379d3d0087a6
4
+ data.tar.gz: da77c34e7d3266080224c70e49535273963b93d4
5
5
  SHA512:
6
- metadata.gz: c9af5980662e32de67a8b82fe18b31643a5ec77f76c1314587dd8e32045d3bfeac449e790d459f2726cf4dc33eb5a0d530c09cd786a874189e4a27450c5ac804
7
- data.tar.gz: f7cd412ac99de4bd45b62077a977d99db568408b710ab85af44ff17c8f9eb04b14064579adafd4f68a58a6e3601f693cb5e2690fd4c24128537fb4fe56ce5ab0
6
+ metadata.gz: 5dbde07ba469e1f1c4d6120bac0856037e7047a776308de7285c6378bb83c1ebf366550498eb894591f374d3982f3caae98d36466da5ba2beeb3c4835295d852
7
+ data.tar.gz: 088ce1eb0e4845edfaad0b804a5b8347d65a3eb8c5bfcb25bf6c005212858e6ee08bbf180905bfbebd4561f44187348c346fa86d1bcfade1ded9a05708a21702
@@ -0,0 +1,5 @@
1
+ Please only file issues here that you believe represent actual bugs or feature requests for the Stripe Ruby library.
2
+
3
+ If you're having general trouble with your Stripe integration, please reach out to support using the form at https://support.stripe.com/ (preferred) or via email to support@stripe.com.
4
+
5
+ If you are reporting a bug, please include your Ruby version and the version of the Stripe Ruby library you're using, as well as any other details that may be helpful in reproducing the problem.
@@ -1,3 +1,7 @@
1
+ === 1.56.1 2016-11-09
2
+
3
+ * Fix (fairly serious) memory like in `StripeObject`
4
+
1
5
  === 1.56.0 2016-10-24
2
6
 
3
7
  * Add accessors for new fields added in `#update_attributes`
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.56.0
1
+ 1.56.1
@@ -145,12 +145,6 @@ module Stripe
145
145
  construct_from(values, opts)
146
146
  end
147
147
 
148
- if RUBY_VERSION < '1.9.2'
149
- def respond_to?(symbol)
150
- @values.has_key?(symbol) || super
151
- end
152
- end
153
-
154
148
  # Sets all keys within the StripeObject as unsaved so that they will be
155
149
  # included with an update when #serialize_params is called. This method is
156
150
  # also recursive, so any StripeObjects contained as values or which are
@@ -214,9 +208,13 @@ module Stripe
214
208
  keys.each do |k|
215
209
  next if f.include?(k)
216
210
  next if @@permanent_attributes.include?(k)
217
- k_eq = :"#{k}="
218
- remove_method(k) if method_defined?(k)
219
- remove_method(k_eq) if method_defined?(k_eq)
211
+
212
+ # Remove methods for the accessor's reader and writer.
213
+ [k, :"#{k}=", :"#{k}?"].each do |method_name|
214
+ if method_defined?(method_name)
215
+ remove_method(method_name)
216
+ end
217
+ end
220
218
  end
221
219
  end
222
220
  end
@@ -227,9 +225,9 @@ module Stripe
227
225
  keys.each do |k|
228
226
  next if f.include?(k)
229
227
  next if @@permanent_attributes.include?(k)
230
- k_eq = :"#{k}="
228
+
231
229
  define_method(k) { @values[k] }
232
- define_method(k_eq) do |v|
230
+ define_method(:"#{k}=") do |v|
233
231
  if v == ""
234
232
  raise ArgumentError.new(
235
233
  "You cannot set #{k} to an empty string. " \
@@ -242,8 +240,7 @@ module Stripe
242
240
  end
243
241
 
244
242
  if [FalseClass, TrueClass].include?(values[k].class)
245
- k_bool = :"#{k}?"
246
- define_method(k_bool) { @values[k] }
243
+ define_method(:"#{k}?") { @values[k] }
247
244
  end
248
245
  end
249
246
  end
@@ -305,10 +302,8 @@ module Stripe
305
302
  # customer, where there is no persistent card parameter. Mark those values
306
303
  # which don't persist as transient
307
304
 
308
- instance_eval do
309
- remove_accessors(removed)
310
- add_accessors(added, values)
311
- end
305
+ remove_accessors(removed)
306
+ add_accessors(added, values)
312
307
 
313
308
  removed.each do |k|
314
309
  @values.delete(k)
@@ -63,7 +63,7 @@ module Stripe
63
63
  # array of +StripeObject+s. These new objects will be created as a concrete
64
64
  # type as dictated by their `object` field (e.g. an `object` value of
65
65
  # `charge` would create an instance of +Charge+), but if `object` is not
66
- # present or of an unkown type, the newly created instance will fall back
66
+ # present or of an unknown type, the newly created instance will fall back
67
67
  # to being a +StripeObject+.
68
68
  #
69
69
  # ==== Attributes
@@ -1,3 +1,3 @@
1
1
  module Stripe
2
- VERSION = '1.56.0'
2
+ VERSION = '1.56.1'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: stripe
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.56.0
4
+ version: 1.56.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Stripe
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-10-24 00:00:00.000000000 Z
11
+ date: 2016-11-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rest-client
@@ -38,6 +38,7 @@ executables:
38
38
  extensions: []
39
39
  extra_rdoc_files: []
40
40
  files:
41
+ - ".github/ISSUE_TEMPLATE.md"
41
42
  - ".gitignore"
42
43
  - ".travis.yml"
43
44
  - CONTRIBUTORS