pay 11.2.3 → 11.3.0
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 +4 -4
- data/app/models/pay/stripe/payment_method.rb +1 -1
- data/app/models/pay/stripe/subscription.rb +2 -4
- data/lib/pay/stripe.rb +1 -1
- data/lib/pay/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 9edcf51b1a6346022cd5d504b2d6e730dadeb31580ae60da69b3f5c5414b97d8
|
|
4
|
+
data.tar.gz: 9cd3ea459bdd0f853efab3a72f32af739125740f22e78f756da1e6ea2a059a5e
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 3e92c7fd1cd767d5d67160abd1bda24d1d9a9c56a4ea3ea883a1be04e65bdaf21fc5a2ad4c9268cad9d37747e6927f79bfcc4beadecbf3f6c79e499d7c890c64
|
|
7
|
+
data.tar.gz: ca5742925df0d3f6aaae8ed148a9710f5c1be43394c0918eb2f0afcba9cf3968546e9388768b98ff3181df8c8e9ddb83ad7ae8d27a5d1266100863e4dcb0b2d8
|
|
@@ -31,7 +31,7 @@ module Pay
|
|
|
31
31
|
return
|
|
32
32
|
end
|
|
33
33
|
|
|
34
|
-
default_payment_method_id = pay_customer.api_record.invoice_settings
|
|
34
|
+
default_payment_method_id = pay_customer.api_record.invoice_settings&.default_payment_method
|
|
35
35
|
default = (id == default_payment_method_id)
|
|
36
36
|
|
|
37
37
|
attributes = extract_attributes(object).merge(default: default, stripe_account: stripe_account)
|
|
@@ -279,7 +279,6 @@ module Pay
|
|
|
279
279
|
unpause
|
|
280
280
|
else
|
|
281
281
|
@api_record = ::Stripe::Subscription.update(processor_id, {
|
|
282
|
-
plan: processor_plan,
|
|
283
282
|
trial_end: (on_trial? ? trial_ends_at.to_i : "now"),
|
|
284
283
|
cancel_at_period_end: false
|
|
285
284
|
}.merge(expand_options),
|
|
@@ -300,10 +299,9 @@ module Pay
|
|
|
300
299
|
processor_id,
|
|
301
300
|
{
|
|
302
301
|
cancel_at_period_end: false,
|
|
303
|
-
plan: plan,
|
|
302
|
+
items: [{id: subscription_items.first.id, plan: plan, quantity: quantity}],
|
|
304
303
|
proration_behavior: proration_behavior,
|
|
305
|
-
trial_end: (on_trial? ? trial_ends_at.to_i : "now")
|
|
306
|
-
quantity: quantity
|
|
304
|
+
trial_end: (on_trial? ? trial_ends_at.to_i : "now")
|
|
307
305
|
}.merge(expand_options).merge(options),
|
|
308
306
|
stripe_options
|
|
309
307
|
)
|
data/lib/pay/stripe.rb
CHANGED
data/lib/pay/version.rb
CHANGED