From 11e8c03c18ed46ed56e25fec01662e150de2961c Mon Sep 17 00:00:00 2001 From: Justas Brazauskas Date: Sun, 13 Dec 2015 18:00:39 +0200 Subject: [PATCH] Fix typos found across repository Signed-off-by: Justas Brazauskas --- docs/auth.go | 2 +- docs/endpoint.go | 2 +- docs/session.go | 4 ++-- docs/types.go | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/docs/auth.go b/docs/auth.go index c3f09a424..e21ee4bc8 100644 --- a/docs/auth.go +++ b/docs/auth.go @@ -38,7 +38,7 @@ func loginV1(authConfig *cliconfig.AuthConfig, registryEndpoint *Endpoint) (stri loginAgainstOfficialIndex := serverAddress == IndexServer - // to avoid sending the server address to the server it should be removed before being marshalled + // to avoid sending the server address to the server it should be removed before being marshaled authCopy := *authConfig authCopy.ServerAddress = "" diff --git a/docs/endpoint.go b/docs/endpoint.go index 20805767c..72892a99f 100644 --- a/docs/endpoint.go +++ b/docs/endpoint.go @@ -125,7 +125,7 @@ type Endpoint struct { URLBuilder *v2.URLBuilder } -// Get the formated URL for the root of this registry Endpoint +// Get the formatted URL for the root of this registry Endpoint func (e *Endpoint) String() string { return fmt.Sprintf("%s/v%d/", e.URL, e.Version) } diff --git a/docs/session.go b/docs/session.go index 5017aeaca..cecf936b2 100644 --- a/docs/session.go +++ b/docs/session.go @@ -100,8 +100,8 @@ func (tr *authTransport) RoundTrip(orig *http.Request) (*http.Response, error) { // Authorization should not be set on 302 redirect for untrusted locations. // This logic mirrors the behavior in addRequiredHeadersToRedirectedRequests. // As the authorization logic is currently implemented in RoundTrip, - // a 302 redirect is detected by looking at the Referer header as go http package adds said header. - // This is safe as Docker doesn't set Referer in other scenarios. + // a 302 redirect is detected by looking at the Referrer header as go http package adds said header. + // This is safe as Docker doesn't set Referrer in other scenarios. if orig.Header.Get("Referer") != "" && !trustedLocation(orig) { return tr.RoundTripper.RoundTrip(orig) } diff --git a/docs/types.go b/docs/types.go index 8a201a917..9b2562f96 100644 --- a/docs/types.go +++ b/docs/types.go @@ -26,7 +26,7 @@ type SearchResults struct { Query string `json:"query"` // NumResults indicates the number of results the query returned NumResults int `json:"num_results"` - // Results is a slice containing the acutal results for the search + // Results is a slice containing the actual results for the search Results []SearchResult `json:"results"` }