stripe 1.15.0 → 1.16.0

Sign up to get free protection for your applications and to get access to all the features.
data/Gemfile CHANGED
@@ -1,7 +1,7 @@
1
1
  source "https://rubygems.org"
2
2
  gemspec
3
3
 
4
- if Gem::Version.new(RUBY_VERSION) < Gem::Version.new('1.9.3')
4
+ if Gem::Version.new(RUBY_VERSION.dup) < Gem::Version.new('1.9.3')
5
5
  gem 'rest-client', '~> 1.6.8'
6
6
  gem 'activesupport', '~> 3.2'
7
7
  end
data/History.txt CHANGED
@@ -1,3 +1,8 @@
1
+ === 1.16.0 2014-10-08
2
+
3
+ * 1 minor enhacement:
4
+ * Coupons now support update operations - useful for manipulating metadata.
5
+
1
6
  === 1.15.0 2014-07-26
2
7
 
3
8
  * 1 major enhacement:
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.15.0
1
+ 1.16.0
data/lib/stripe.rb CHANGED
@@ -259,26 +259,31 @@ module Stripe
259
259
  end
260
260
 
261
261
  def self.handle_restclient_error(e)
262
- case e
263
- when RestClient::ServerBrokeConnection, RestClient::RequestTimeout
264
- message = "Could not connect to Stripe (#{@api_base}). " +
265
- "Please check your internet connection and try again. " +
266
- "If this problem persists, you should check Stripe's service status at " +
262
+ connection_message = "Please check your internet connection and try again. " \
263
+ "If this problem persists, you should check Stripe's service status at " \
267
264
  "https://twitter.com/stripestatus, or let us know at support@stripe.com."
268
265
 
266
+ case e
267
+ when RestClient::RequestTimeout
268
+ message = "Could not connect to Stripe (#{@api_base}). #{connection_message}"
269
+
270
+ when RestClient::ServerBrokeConnection
271
+ message = "The connection to the server (#{@api_base}) broke before the " \
272
+ "request completed. #{connection_message}"
273
+
269
274
  when RestClient::SSLCertificateNotVerified
270
- message = "Could not verify Stripe's SSL certificate. " +
271
- "Please make sure that your network is not intercepting certificates. " +
272
- "(Try going to https://api.stripe.com/v1 in your browser.) " +
275
+ message = "Could not verify Stripe's SSL certificate. " \
276
+ "Please make sure that your network is not intercepting certificates. " \
277
+ "(Try going to https://api.stripe.com/v1 in your browser.) " \
273
278
  "If this problem persists, let us know at support@stripe.com."
274
279
 
275
280
  when SocketError
276
- message = "Unexpected error communicating when trying to connect to Stripe. " +
277
- "You may be seeing this message because your DNS is not working. " +
281
+ message = "Unexpected error communicating when trying to connect to Stripe. " \
282
+ "You may be seeing this message because your DNS is not working. " \
278
283
  "To check, try running 'host stripe.com' from the command line."
279
284
 
280
285
  else
281
- message = "Unexpected error communicating with Stripe. " +
286
+ message = "Unexpected error communicating with Stripe. " \
282
287
  "If this problem persists, let us know at support@stripe.com."
283
288
 
284
289
  end
data/lib/stripe/coupon.rb CHANGED
@@ -1,6 +1,7 @@
1
1
  module Stripe
2
2
  class Coupon < APIResource
3
3
  include Stripe::APIOperations::Create
4
+ include Stripe::APIOperations::Update
4
5
  include Stripe::APIOperations::Delete
5
6
  include Stripe::APIOperations::List
6
7
  end
@@ -1,3 +1,3 @@
1
1
  module Stripe
2
- VERSION = '1.15.0'
2
+ VERSION = '1.16.0'
3
3
  end
metadata CHANGED
@@ -1,7 +1,8 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: stripe
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.15.0
4
+ version: 1.16.0
5
+ prerelease:
5
6
  platform: ruby
6
7
  authors:
7
8
  - Ross Boucher
@@ -9,11 +10,12 @@ authors:
9
10
  autorequire:
10
11
  bindir: bin
11
12
  cert_chain: []
12
- date: 2014-07-30 00:00:00.000000000 Z
13
+ date: 2014-10-08 00:00:00.000000000 Z
13
14
  dependencies:
14
15
  - !ruby/object:Gem::Dependency
15
16
  name: rest-client
16
17
  requirement: !ruby/object:Gem::Requirement
18
+ none: false
17
19
  requirements:
18
20
  - - ~>
19
21
  - !ruby/object:Gem::Version
@@ -21,6 +23,7 @@ dependencies:
21
23
  type: :runtime
22
24
  prerelease: false
23
25
  version_requirements: !ruby/object:Gem::Requirement
26
+ none: false
24
27
  requirements:
25
28
  - - ~>
26
29
  - !ruby/object:Gem::Version
@@ -28,6 +31,7 @@ dependencies:
28
31
  - !ruby/object:Gem::Dependency
29
32
  name: mime-types
30
33
  requirement: !ruby/object:Gem::Requirement
34
+ none: false
31
35
  requirements:
32
36
  - - ! '>='
33
37
  - !ruby/object:Gem::Version
@@ -38,6 +42,7 @@ dependencies:
38
42
  type: :runtime
39
43
  prerelease: false
40
44
  version_requirements: !ruby/object:Gem::Requirement
45
+ none: false
41
46
  requirements:
42
47
  - - ! '>='
43
48
  - !ruby/object:Gem::Version
@@ -48,6 +53,7 @@ dependencies:
48
53
  - !ruby/object:Gem::Dependency
49
54
  name: json
50
55
  requirement: !ruby/object:Gem::Requirement
56
+ none: false
51
57
  requirements:
52
58
  - - ~>
53
59
  - !ruby/object:Gem::Version
@@ -55,6 +61,7 @@ dependencies:
55
61
  type: :runtime
56
62
  prerelease: false
57
63
  version_requirements: !ruby/object:Gem::Requirement
64
+ none: false
58
65
  requirements:
59
66
  - - ~>
60
67
  - !ruby/object:Gem::Version
@@ -62,6 +69,7 @@ dependencies:
62
69
  - !ruby/object:Gem::Dependency
63
70
  name: mocha
64
71
  requirement: !ruby/object:Gem::Requirement
72
+ none: false
65
73
  requirements:
66
74
  - - ~>
67
75
  - !ruby/object:Gem::Version
@@ -69,6 +77,7 @@ dependencies:
69
77
  type: :development
70
78
  prerelease: false
71
79
  version_requirements: !ruby/object:Gem::Requirement
80
+ none: false
72
81
  requirements:
73
82
  - - ~>
74
83
  - !ruby/object:Gem::Version
@@ -76,6 +85,7 @@ dependencies:
76
85
  - !ruby/object:Gem::Dependency
77
86
  name: shoulda
78
87
  requirement: !ruby/object:Gem::Requirement
88
+ none: false
79
89
  requirements:
80
90
  - - ~>
81
91
  - !ruby/object:Gem::Version
@@ -83,6 +93,7 @@ dependencies:
83
93
  type: :development
84
94
  prerelease: false
85
95
  version_requirements: !ruby/object:Gem::Requirement
96
+ none: false
86
97
  requirements:
87
98
  - - ~>
88
99
  - !ruby/object:Gem::Version
@@ -90,6 +101,7 @@ dependencies:
90
101
  - !ruby/object:Gem::Dependency
91
102
  name: test-unit
92
103
  requirement: !ruby/object:Gem::Requirement
104
+ none: false
93
105
  requirements:
94
106
  - - ! '>='
95
107
  - !ruby/object:Gem::Version
@@ -97,6 +109,7 @@ dependencies:
97
109
  type: :development
98
110
  prerelease: false
99
111
  version_requirements: !ruby/object:Gem::Requirement
112
+ none: false
100
113
  requirements:
101
114
  - - ! '>='
102
115
  - !ruby/object:Gem::Version
@@ -104,6 +117,7 @@ dependencies:
104
117
  - !ruby/object:Gem::Dependency
105
118
  name: rake
106
119
  requirement: !ruby/object:Gem::Requirement
120
+ none: false
107
121
  requirements:
108
122
  - - ! '>='
109
123
  - !ruby/object:Gem::Version
@@ -111,6 +125,7 @@ dependencies:
111
125
  type: :development
112
126
  prerelease: false
113
127
  version_requirements: !ruby/object:Gem::Requirement
128
+ none: false
114
129
  requirements:
115
130
  - - ! '>='
116
131
  - !ruby/object:Gem::Version
@@ -198,26 +213,27 @@ files:
198
213
  homepage: https://stripe.com/api
199
214
  licenses:
200
215
  - MIT
201
- metadata: {}
202
216
  post_install_message:
203
217
  rdoc_options: []
204
218
  require_paths:
205
219
  - lib
206
220
  required_ruby_version: !ruby/object:Gem::Requirement
221
+ none: false
207
222
  requirements:
208
223
  - - ! '>='
209
224
  - !ruby/object:Gem::Version
210
225
  version: '0'
211
226
  required_rubygems_version: !ruby/object:Gem::Requirement
227
+ none: false
212
228
  requirements:
213
229
  - - ! '>='
214
230
  - !ruby/object:Gem::Version
215
231
  version: '0'
216
232
  requirements: []
217
233
  rubyforge_project:
218
- rubygems_version: 2.2.2
234
+ rubygems_version: 1.8.23
219
235
  signing_key:
220
- specification_version: 4
236
+ specification_version: 3
221
237
  summary: Ruby bindings for the Stripe API
222
238
  test_files:
223
239
  - test/stripe/account_test.rb
checksums.yaml DELETED
@@ -1,15 +0,0 @@
1
- ---
2
- !binary "U0hBMQ==":
3
- metadata.gz: !binary |-
4
- YjY0ZDhkYjEyMTQyYTc0Y2Q3ZDYxZDk0ZjI3YWU4NGRmMjA0YTQ5Yg==
5
- data.tar.gz: !binary |-
6
- MGZhN2E0NzAwOTA0MmJkNDcyYzFjZDgzZWVjOGEzOTczOTA0NGI0YQ==
7
- SHA512:
8
- metadata.gz: !binary |-
9
- ZWNiNzc5YTk2MThkNmIwZDlmNjg4YjI2ZmQ4ZGE4MTk0OGZjYmU4N2M4Zjdm
10
- MzEyMjJiNjkwMTQ4NjkyYjFmNWE4YzI0MjY2ZTA5NTE4ODE5ZGVjNmNiMDBi
11
- MThhNDQyYTUyM2I1NjVhZjc5ZjdjNjAzZTAyZjI1NjE3ZjEyNmU=
12
- data.tar.gz: !binary |-
13
- Y2U1NTk4ZGJlMWVmYjI0ZTgzOWIyYzg5MzIwYTdlNGI4NDU0YTA0ZWMxZjU0
14
- YjNjMzlmYTBkMWRiN2M4YTEzNmE3MzUyMDViNzkyNGUyZTE3MDdmZDU3OTNj
15
- ZGUzNjI1ZWQ2YzMzMGJiODBjM2VkNjYxYjA2ZGYzNzEzMTI2YmE=