Skip to content

Commit

Permalink
fix typos
Browse files Browse the repository at this point in the history
Signed-off-by: allencloud <[email protected]>
  • Loading branch information
allencloud committed Mar 5, 2016
1 parent 160abfb commit 2736f77
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion api/common_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -310,7 +310,7 @@ func TestLoadOrCreateTrustKeyCreateKey(t *testing.T) {
}

// With the need to create the folder hierarchy as tmpKeyFie is in a path
// where some folder do not exists.
// where some folders do not exist.
tmpKeyFile = filepath.Join(tmpKeyFolderPath, "folder/hierarchy/keyfile")

if key, err := LoadOrCreateTrustKey(tmpKeyFile); err != nil || key == nil {
Expand Down
4 changes: 2 additions & 2 deletions api/server/httputils/httputils.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import (
const APIVersionKey = "api-version"

// APIFunc is an adapter to allow the use of ordinary functions as Docker API endpoints.
// Any function that has the appropriate signature can be register as a API endpoint (e.g. getVersion).
// Any function that has the appropriate signature can be registered as a API endpoint (e.g. getVersion).
type APIFunc func(ctx context.Context, w http.ResponseWriter, r *http.Request, vars map[string]string) error

// HijackConnection interrupts the http response writer to get the
Expand Down Expand Up @@ -75,7 +75,7 @@ func ParseForm(r *http.Request) error {
return nil
}

// ParseMultipartForm ensure the request form is parsed, even with invalid content types.
// ParseMultipartForm ensures the request form is parsed, even with invalid content types.
func ParseMultipartForm(r *http.Request) error {
if err := r.ParseMultipartForm(4096); err != nil && !strings.HasPrefix(err.Error(), "mime:") {
return err
Expand Down
2 changes: 1 addition & 1 deletion api/server/middleware/middleware.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@ package middleware
import "github.com/docker/docker/api/server/httputils"

// Middleware is an adapter to allow the use of ordinary functions as Docker API filters.
// Any function that has the appropriate signature can be register as a middleware.
// Any function that has the appropriate signature can be registered as a middleware.
type Middleware func(handler httputils.APIFunc) httputils.APIFunc
4 changes: 2 additions & 2 deletions api/server/router/network/filter.go
Original file line number Diff line number Diff line change
Expand Up @@ -84,8 +84,8 @@ func filterNetworkByID(nws []libnetwork.Network, id string) (retNws []libnetwork
return retNws, nil
}

// filterAllNetworks filter network list according to user specified filter
// and return user chosen networks
// filterAllNetworks filters network list according to user specified filter
// and returns user chosen networks
func filterNetworks(nws []libnetwork.Network, filter filters.Args) ([]libnetwork.Network, error) {
// if filter is empty, return original network list
if filter.Len() == 0 {
Expand Down
2 changes: 1 addition & 1 deletion api/server/router_swapper.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (
"github.com/gorilla/mux"
)

// routerSwapper is an http.Handler that allow you to swap
// routerSwapper is an http.Handler that allows you to swap
// mux routers.
type routerSwapper struct {
mu sync.Mutex
Expand Down

0 comments on commit 2736f77

Please sign in to comment.