Money.Subscription.latest_plan

You're seeing just the function latest_plan, go back to Money.Subscription module for more information.

Specs

Returns the latest plan for a subscription.

The latest plan may not be in affect since its start date may be in the future.

Arguments

  • subscription is a Money.Subscription.t or any map that provides the field :plans

Returns

  • The Money.Subscription.Plan.t that is the most recent plan - whether or not it is the currently active plan.