diff --git a/templates/download-result.html b/templates/download-result.html
index 31e6e93..1316264 100644
--- a/templates/download-result.html
+++ b/templates/download-result.html
@@ -8,6 +8,6 @@
-Internal Error. Try Again later
+Internal Error. Try Again later
{{ end }}
diff --git a/yt.go b/yt.go
index 6bd6321..b48f430 100644
--- a/yt.go
+++ b/yt.go
@@ -31,7 +31,11 @@ func isValidURL(data string) bool {
}
- httpClient := &http.Client{}
+ httpClient := &http.Client{
+ CheckRedirect: func(req *http.Request, via []*http.Request) error {
+ return http.ErrUseLastResponse
+ },
+ }
resp, err := httpClient.Get(data)
if err != nil {