format some code in dockershim

This commit is contained in:
Yuhao Fang
2017-10-08 22:30:37 +08:00
parent d2bbeb6665
commit c1c89d986b
3 changed files with 3 additions and 5 deletions

View File

@@ -325,9 +325,8 @@ func (ds *dockerService) GetPodPortMappings(podSandboxID string) ([]*hostport.Po
if err == errors.CheckpointNotFoundError {
glog.Warningf("Failed to retrieve checkpoint for sandbox %q: %v", podSandboxID, err)
return nil, nil
} else {
return nil, err
}
return nil, err
}
portMappings := make([]*hostport.PortMapping, 0, len(checkpoint.Data.PortMappings))

View File

@@ -372,9 +372,8 @@ func (f *FakeDockerClient) popError(op string) error {
if ok {
delete(f.Errors, op)
return err
} else {
return nil
}
return nil
}
// ListContainers is a test-spy implementation of Interface.ListContainers.

View File

@@ -32,7 +32,7 @@ type instrumentedInterface struct {
client Interface
}
// Creates an instrumented Interface from an existing Interface.
// NewInstrumentedInterface creates an instrumented Interface from an existing Interface.
func NewInstrumentedInterface(dockerClient Interface) Interface {
return instrumentedInterface{
client: dockerClient,