|
if strings.HasSuffix(u.Hostname(), "github.com") { |
|
return newDotcomHost() |
|
} |
It's possible for a Github Enterprise server to end in github.com, i.e. mycompanygithub.com, so any requests will still forward to api.github.com even if that's not the right hostname.