Fetcher retrieves token scopes from GitHub's API. It uses an HTTP HEAD request to minimize bandwidth since we only need headers.
| 36 | // Fetcher retrieves token scopes from GitHub's API. |
| 37 | // It uses an HTTP HEAD request to minimize bandwidth since we only need headers. |
| 38 | type Fetcher struct { |
| 39 | client *http.Client |
| 40 | apiHost utils.APIHostResolver |
| 41 | } |
| 42 | |
| 43 | // NewFetcher creates a new scope fetcher with the given options. |
| 44 | func NewFetcher(apiHost utils.APIHostResolver, opts FetcherOptions) *Fetcher { |
nothing calls this directly
no outgoing calls
no test coverage detected