mirror of
https://github.com/superseriousbusiness/gotosocial.git
synced 2024-10-31 22:18:52 +00:00
use errors.AsV2()
This commit is contained in:
parent
3c9451b327
commit
175c8700d1
1 changed files with 2 additions and 2 deletions
|
@ -291,8 +291,8 @@ func (c *Client) do(r *request) (*http.Response, bool /* retry */, error) {
|
|||
return nil, false, err
|
||||
}
|
||||
|
||||
if dnserr := (*net.DNSError)(nil); // nocollapse
|
||||
errors.As(err, &dnserr) && dnserr.IsNotFound {
|
||||
if dnserr := errorsv2.AsV2[*net.DNSError](err); // nocollapse
|
||||
dnserr != nil && dnserr.IsNotFound {
|
||||
// DNS lookup failure, this domain does not exist
|
||||
return nil, false, gtserror.SetNotFound(err)
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue