Skip to content

Commit 0c7c495

Browse files
committed
pkg/runtime-tools/generate: remove embedded field "Generator"
Makes linters happier. Signed-off-by: Markus Lehtonen <markus.lehtonen@intel.com>
1 parent 2f815c1 commit 0c7c495

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

pkg/runtime-tools/generate/generate.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -504,15 +504,15 @@ func (g *Generator) AdjustMounts(mounts []*nri.Mount) error {
504504

505505
// sortMounts sorts the mounts in the generated OCI Spec.
506506
func (g *Generator) sortMounts() {
507-
mounts := g.Generator.Mounts()
508-
g.Generator.ClearMounts()
507+
mounts := g.Mounts()
508+
g.ClearMounts()
509509
sort.Sort(orderedMounts(mounts))
510510

511511
// TODO(klihub): This is now a bit ugly maybe we should introduce a
512512
// SetMounts([]rspec.Mount) to runtime-tools/generate.Generator. That
513513
// could also take care of properly sorting the mount slice.
514514

515-
g.Generator.Config.Mounts = mounts
515+
g.Config.Mounts = mounts
516516
}
517517

518518
// orderedMounts defines how to sort an OCI Spec Mount slice.

0 commit comments

Comments
 (0)