Skip to content
This repository has been archived by the owner on Feb 2, 2022. It is now read-only.

Commit

Permalink
Merge pull request #218 from asamMarkus/develop
Browse files Browse the repository at this point in the history
Bugfix in Subscription::scheduleNewOrderItemAt
  • Loading branch information
sandervanhooft committed Jun 5, 2020
2 parents a77b211 + 9290cf8 commit 26fa67c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/Subscription.php
Expand Up @@ -418,7 +418,7 @@ public function scheduleNewOrderItemAt(Carbon $process_at, $item_overrides = [],
'unit_price' => (int) $plan->amount()->getAmount(),
'quantity' => $this->quantity ?: 1,
'tax_percentage' => $this->tax_percentage,
'description' => $this->plan()->description(),
'description' => $plan->description(),
], $item_overrides
));

Expand Down
1 change: 1 addition & 0 deletions tests/SwapSubscriptionPlanTest.php
Expand Up @@ -138,6 +138,7 @@ public function canSwapNextCycle()
$this->assertCarbon($cycle_should_end_at, $new_order_item->process_at, 1); // based on previous plan's cycle
$this->assertEquals(2200, $new_order_item->total);
$this->assertEquals(200, $new_order_item->tax);
$this->assertEquals('Twice as expensive monthly subscription', $new_order_item->description);

$this->assertFalse($user->fresh()->hasCredit());

Expand Down

0 comments on commit 26fa67c

Please sign in to comment.