Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix type spec of Mailer.deliver_later/1 (#584)
What changed? ============ This commit updates the `Mailer.deliver_later/1` `@spec` for the function found in `__using__`. It seems to not have been updated with the release of Bamboo 2.0. Why? ----- After updating to 2.0.0, dialyzer fails with a message like this: lib/my_app/mailer/mailgun.ex:17:invalid_contract The @SPEC for the function does not match the success typing of the function. Function: MyApp.Mailer.Mailgun.BambooMailer.deliver_later/1 Success typing: @SPEC deliver_later(_) :: {:error, <<_::64, _::size(8)>> | %{ :__exception__ => true, :__struct__ => Bamboo.EmptyFromAddressError | Bamboo.NilRecipientsError, :message => <<_::64, _::size(8)>> }} | {:ok, %{ :bcc => {binary(), binary()}, :cc => {binary(), binary()}, :from => {binary(), binary()}, :to => {binary(), binary()}, _ => _ }} ________________________________________________________________________________ done (warnings were emitted)
- Loading branch information