pay 8.2.0 → 8.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
  SHA256:
3
- metadata.gz: 508c9227734d74f5b2bc54796fa176fb712d7028ac6a81eeeff6c3366b271190
4
- data.tar.gz: f21dc281d1ab89d2bb11c77b41ebefeed886b193d98551b751a881faaf6b8733
3
+ metadata.gz: fabadba6082c91114d763242a738a19dab355dde46f6079a4ae474b9ba64c538
4
+ data.tar.gz: 4348766c53d5630613dacf04a61d1f49714076f91de1e0594625cf088072b61f
5
5
  SHA512:
6
- metadata.gz: 1ab54cc78bb095352008d705439e86081e2f8348e253ec610e04d39cbefb305a8e93999fc112379ad8ef0c614e3fe7e658532510bae92b6b405c195ddd65d154
7
- data.tar.gz: 9908d0317fda0cd3c0f849fb43ef529c57b742442faa1278ac0ea9bd1c1aa326845acb009f87269ecaa3841c1ef53e686de1052b3909e55b98b379aa8a264eab
6
+ metadata.gz: 8886673e5e4a1ee8d478c9214861e1b8ba2032d3f54b50664ece5cebd7d1545ef8945f167d87455ffaf739a6b758b016d297069889bb7b47efaf47028928e09a
7
+ data.tar.gz: b91bd40b0de1d41b191faa0f2fccacb3de48fc2b3fa83698df75897b93de065b11a132d9958e1f31572d2cf4c57e372aa2d7033844226c5f71eeef8dfe49f68e
@@ -174,7 +174,7 @@ module Pay
174
174
  return if canceled? && ends_at.past?
175
175
 
176
176
  @api_record = ::Stripe::Subscription.cancel(processor_id, options.merge(expand_options), stripe_options)
177
- update(ends_at: Time.current, status: :canceled)
177
+ update(trial_ends_at: Time.current, ends_at: Time.current, status: :canceled)
178
178
  rescue ::Stripe::StripeError => e
179
179
  raise Pay::Stripe::Error, e
180
180
  end
@@ -68,7 +68,9 @@ module Pay
68
68
  "subscription-invoices" => ::LemonSqueezy::SubscriptionInvoice
69
69
  }.fetch(data["type"])
70
70
 
71
- type.new(data)
71
+ object = type.new(data)
72
+ object.meta = event["meta"]
73
+ object
72
74
  end
73
75
  end
74
76
 
data/lib/pay/nano_id.rb CHANGED
@@ -5,7 +5,7 @@ module Pay
5
5
  ALPHABET_SIZE = ALPHABET.size
6
6
 
7
7
  def self.generate(size: 21)
8
- id = ""
8
+ id = +""
9
9
  size.times { id << ALPHABET[(Random.rand * ALPHABET_SIZE).floor] }
10
10
  id
11
11
  end
@@ -61,7 +61,7 @@ module Pay
61
61
  # array will be assumed to be an associative array, and will be serialized
62
62
  # as a PHP associative array rather than a multidimensional array.
63
63
  def serialize(var, assoc = false)
64
- s = ""
64
+ s = +""
65
65
  case var
66
66
  when Array
67
67
  s << "a:#{var.size}:{"
data/lib/pay/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Pay
2
- VERSION = "8.2.0"
2
+ VERSION = "8.2.2"
3
3
  end
metadata CHANGED
@@ -1,16 +1,16 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pay
3
3
  version: !ruby/object:Gem::Version
4
- version: 8.2.0
4
+ version: 8.2.2
5
5
  platform: ruby
6
+ original_platform: ''
6
7
  authors:
7
8
  - Jason Charnes
8
9
  - Chris Oliver
9
10
  - Collin Jilbert
10
- autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2024-11-19 00:00:00.000000000 Z
13
+ date: 2024-12-13 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: rails
@@ -165,7 +165,6 @@ homepage: https://github.com/pay-rails/pay
165
165
  licenses:
166
166
  - MIT
167
167
  metadata: {}
168
- post_install_message:
169
168
  rdoc_options: []
170
169
  require_paths:
171
170
  - lib
@@ -180,8 +179,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
180
179
  - !ruby/object:Gem::Version
181
180
  version: '0'
182
181
  requirements: []
183
- rubygems_version: 3.5.23
184
- signing_key:
182
+ rubygems_version: 3.6.0.dev
185
183
  specification_version: 4
186
184
  summary: Payments engine for Ruby on Rails
187
185
  test_files: []