Simplified Code

This commit is contained in:
Timo Müller
2020-06-08 08:14:44 +00:00
committed by GitHub
parent d1ad649b8c
commit 60c045ca85
+3 -4
View File
@@ -56,10 +56,9 @@ func New(options *Options) (*HTTPX, error) {
var oldHost = previousRequest[0].URL.Host
if newHost != oldHost{
return http.ErrUseLastResponse // Tell the http client to not follow redirect
} else {
// Go through with the redirect
return nil
}
}
return nil
}
}