Add support for /ytc/ - channel avatars.
This commit is contained in:
parent
002de23657
commit
a8981a44c7
1 changed files with 2 additions and 1 deletions
3
main.go
3
main.go
|
@ -106,7 +106,7 @@ func getHost(path string) (host string) {
|
||||||
host = "yt3.ggpht.com"
|
host = "yt3.ggpht.com"
|
||||||
}
|
}
|
||||||
|
|
||||||
if strings.HasPrefix(path, "/a/") {
|
if strings.HasPrefix(path, "/a/") || strings.HasPrefix(path, "/ytc/") {
|
||||||
host = "yt3.ggpht.com"
|
host = "yt3.ggpht.com"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -134,6 +134,7 @@ func main() {
|
||||||
http.HandleFunc("/vi/", genericHTTPProxy)
|
http.HandleFunc("/vi/", genericHTTPProxy)
|
||||||
http.HandleFunc("/vi_webp/", genericHTTPProxy)
|
http.HandleFunc("/vi_webp/", genericHTTPProxy)
|
||||||
http.HandleFunc("/a/", genericHTTPProxy)
|
http.HandleFunc("/a/", genericHTTPProxy)
|
||||||
|
http.HandleFunc("/ytc/", genericHTTPProxy)
|
||||||
http.HandleFunc("/ggpht/", genericHTTPProxy)
|
http.HandleFunc("/ggpht/", genericHTTPProxy)
|
||||||
http.HandleFunc("/sb/", genericHTTPProxy)
|
http.HandleFunc("/sb/", genericHTTPProxy)
|
||||||
socket := "socket" + string(os.PathSeparator) + "http-proxy.sock"
|
socket := "socket" + string(os.PathSeparator) + "http-proxy.sock"
|
||||||
|
|
Loading…
Add table
Reference in a new issue