Skip to content
This repository was archived by the owner on Jun 13, 2025. It is now read-only.

Commit 001c804

Browse files
fix: Fix stripe invoice time bounding param names (#966)
1 parent 136300e commit 001c804

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

services/billing.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -175,8 +175,8 @@ def cancel_and_refund(
175175
subscription=owner.stripe_subscription_id,
176176
status="paid",
177177
created={
178-
"created.gte": int(start_of_last_period.timestamp()),
179-
"created.lt": int(current_subscription_datetime.timestamp()),
178+
"gte": int(start_of_last_period.timestamp()),
179+
"lt": int(current_subscription_datetime.timestamp()),
180180
},
181181
)
182182

services/tests/test_billing.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -448,7 +448,7 @@ def test_delete_subscription_with_schedule_releases_schedule_and_cancels_subscri
448448
list_invoice_mock.assert_called_once_with(
449449
subscription=stripe_subscription_id,
450450
status="paid",
451-
created={"created.gte": 1458263420, "created.lt": 1489799420},
451+
created={"gte": 1458263420, "lt": 1489799420},
452452
)
453453
self.assertEqual(create_refund_mock.call_count, 2)
454454
modify_customer_mock.assert_called_once_with(
@@ -523,7 +523,7 @@ def test_delete_subscription_with_schedule_releases_schedule_and_cancels_subscri
523523
list_invoice_mock.assert_called_once_with(
524524
subscription=stripe_subscription_id,
525525
status="paid",
526-
created={"created.gte": 1458263420, "created.lt": 1489799420},
526+
created={"gte": 1458263420, "lt": 1489799420},
527527
)
528528
self.assertEqual(create_refund_mock.call_count, 2)
529529
modify_customer_mock.assert_called_once_with(
@@ -600,7 +600,7 @@ def test_delete_subscription_with_schedule_releases_schedule_and_cancels_subscri
600600
list_invoice_mock.assert_called_once_with(
601601
subscription=stripe_subscription_id,
602602
status="paid",
603-
created={"created.gte": 1458263420, "created.lt": 1489799420},
603+
created={"gte": 1458263420, "lt": 1489799420},
604604
)
605605
create_refund_mock.assert_not_called()
606606
modify_customer_mock.assert_not_called()

0 commit comments

Comments
 (0)