Skip to content

Commit

Permalink
refactor: remove unused parameterisation of containerWithImageNameRen…
Browse files Browse the repository at this point in the history
…derer
  • Loading branch information
bboreham committed Jan 27, 2020
1 parent 875fdba commit f732eed
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions render/container.go
Original file line number Diff line number Diff line change
Expand Up @@ -116,14 +116,12 @@ func HasChildren(topology string) FilterFunc {
}
}

type containerWithImageNameRenderer struct {
Renderer
}
type containerWithImageNameRenderer struct{}

// Render produces a container graph where the the latest metadata contains the
// container image name, if found.
func (r containerWithImageNameRenderer) Render(ctx context.Context, rpt report.Report) Nodes {
containers := r.Renderer.Render(ctx, rpt)
containers := ContainerRenderer.Render(ctx, rpt)
images := SelectContainerImage.Render(ctx, rpt)

outputs := make(report.Nodes, len(containers.Nodes))
Expand Down Expand Up @@ -155,7 +153,7 @@ func (r containerWithImageNameRenderer) Render(ctx context.Context, rpt report.R

// ContainerWithImageNameRenderer is a Renderer which produces a container
// graph where the ranks are the image names, not their IDs
var ContainerWithImageNameRenderer = Memoise(containerWithImageNameRenderer{ContainerRenderer})
var ContainerWithImageNameRenderer = Memoise(containerWithImageNameRenderer{})

// ContainerImageRenderer produces a graph where each node is a container image
// with the original containers as children
Expand Down

0 comments on commit f732eed

Please sign in to comment.