You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -1235,16 +1235,12 @@ When your application receives the `subscription_created` event, Cashier will se
1235
1235
> [!WARNING]
1236
1236
> If the customer's subscription is not canceled before the trial ending date they will be charged as soon as the trial expires, so you should be sure to notify your users of their trial ending date.
1237
1237
1238
-
You may determine if the user is within their trial period using either the `onTrial` method of the user instance or the `onTrial` method of the subscription instance. The two examples below are equivalent:
1238
+
You may determine if the user is within their trial period using either the `onTrial` method of the user instance:
1239
1239
1240
1240
```php
1241
1241
if ($user->onTrial()) {
1242
1242
// ...
1243
1243
}
1244
-
1245
-
if ($user->subscription()->onTrial()) {
1246
-
// ...
1247
-
}
1248
1244
```
1249
1245
1250
1246
To determine if an existing trial has expired, you may use the `hasExpiredTrial` methods:
@@ -1253,10 +1249,6 @@ To determine if an existing trial has expired, you may use the `hasExpiredTrial`
1253
1249
if ($user->hasExpiredTrial()) {
1254
1250
// ...
1255
1251
}
1256
-
1257
-
if ($user->subscription()->hasExpiredTrial()) {
1258
-
// ...
1259
-
}
1260
1252
```
1261
1253
1262
1254
To determine if a user is on trial for a specific subscription type, you may provide the type to the `onTrial` or `hasExpiredTrial` methods:
0 commit comments