Skip to content

Commit

Permalink
[9.x] Document hasExpiredTrial (laravel#7942)
Browse files Browse the repository at this point in the history
* Update billing.md

* Update cashier-paddle.md

* Update billing.md

* Update billing.md

* Update billing.md

* Update cashier-paddle.md

* Update billing.md

* Update billing.md

* Update billing.md

Co-authored-by: Taylor Otwell <taylor@laravel.com>
  • Loading branch information
driesvints and taylorotwell authored May 17, 2022
1 parent f170a2c commit 38177b4
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 0 deletions.
10 changes: 10 additions & 0 deletions billing.md
Original file line number Diff line number Diff line change
Expand Up @@ -1325,6 +1325,16 @@ You may use the `endTrial` method to immediately end a subscription trial:

$user->subscription('default')->endTrial();

To determine if an existing trial has expired, you may use the `hasExpiredTrial` methods:

if ($user->hasExpiredTrial('default')) {
//
}

if ($user->subscription('default')->hasExpiredTrial()) {
//
}

<a name="defining-trial-days-in-stripe-cashier"></a>
#### Defining Trial Days In Stripe / Cashier

Expand Down
10 changes: 10 additions & 0 deletions cashier-paddle.md
Original file line number Diff line number Diff line change
Expand Up @@ -880,6 +880,16 @@ You may determine if the user is within their trial period using either the `onT
//
}

To determine if an existing trial has expired, you may use the `hasExpiredTrial` methods:

if ($user->hasExpiredTrial('default')) {
//
}

if ($user->subscription('default')->hasExpiredTrial()) {
//
}

<a name="defining-trial-days-in-paddle-cashier"></a>
#### Defining Trial Days In Paddle / Cashier

Expand Down

0 comments on commit 38177b4

Please sign in to comment.