Money.Subscription.Plan.new-exclamation-mark

You're seeing just the function new-exclamation-mark, go back to Money.Subscription.Plan module for more information.
Link to this function

new!(price, interval, interval_count \\ 1)

View Source

Specs

new!(Money.t(), interval(), interval_count()) :: t() | no_return()

Returns {:ok, Money.Subscription.Plan.t} or raises an exception.

Takes the same arguments as Money.Subscription.Plan.new/3.

Example

iex> Money.Subscription.Plan.new! Money.new(:USD, 100), :day, 30
%Money.Subscription.Plan{
  interval: :day,
  interval_count: 30,
  price: Money.new(:USD, 100)
}