mirror of
https://github.com/pierre-emmanuelJ/iptv-proxy.git
synced 2026-03-17 07:26:14 +01:00
fixup! Improve restart on 403 forbidden try restart 10 times
Signed-off-by: Pierre-Emmanuel Jacquier <pierre-emmanuel.jacquier@epitech.eu>
This commit is contained in:
@@ -102,6 +102,8 @@ func (p *proxy) reverseProxy(c *gin.Context) {
|
||||
if resp.StatusCode == http.StatusForbidden && forbiddenRestart > 0 {
|
||||
forbiddenRestart--
|
||||
return true
|
||||
} else if resp.StatusCode == http.StatusForbidden {
|
||||
return false
|
||||
}
|
||||
|
||||
copyHTTPHeader(c, resp.Header)
|
||||
|
||||
Reference in New Issue
Block a user