File tree Expand file tree Collapse file tree 2 files changed +18
-0
lines changed
Expand file tree Collapse file tree 2 files changed +18
-0
lines changed Original file line number Diff line number Diff line change @@ -53,11 +53,20 @@ defmodule Mint.HTTPError do
5353 | { :unexpected_status , non_neg_integer ( ) }
5454 | { :unexpected_trailing_responses , list ( ) } }
5555
56+ @ typedoc """
57+ The error reason.
58+ """
59+ @ typedoc since: "1.7.2"
5660 @ type reason :: HTTP1 . error_reason ( ) | HTTP2 . error_reason ( ) | proxy_reason ( ) | term ( )
61+
62+ @ typedoc """
63+ Type for the `Mint.HTTPError` exception struct.
64+ """
5765 @ type t ( ) :: % __MODULE__ { reason: reason ( ) }
5866
5967 defexception [ :reason , :module ]
6068
69+ @ impl true
6170 def message ( % __MODULE__ { reason: reason , module: module } ) do
6271 module . format_error ( reason )
6372 end
Original file line number Diff line number Diff line change @@ -55,11 +55,20 @@ defmodule Mint.TransportError do
5555 reason_type
5656 end
5757
58+ @ typedoc """
59+ The error reason.
60+ """
61+ @ typedoc since: "1.7.2"
5862 @ type reason :: unquote ( reason_type ) | term ( )
63+
64+ @ typedoc """
65+ Type for the `Mint.TransportError` exception struct.
66+ """
5967 @ type t ( ) :: % __MODULE__ { reason: reason ( ) }
6068
6169 defexception [ :reason ]
6270
71+ @ impl true
6372 def message ( % __MODULE__ { reason: reason } ) do
6473 format_reason ( reason )
6574 end
You can’t perform that action at this time.
0 commit comments