diff --git a/kustomize/internal/commands/edit/fix/fix.go b/kustomize/internal/commands/edit/fix/fix.go index 13d9a3136..6600f7849 100644 --- a/kustomize/internal/commands/edit/fix/fix.go +++ b/kustomize/internal/commands/edit/fix/fix.go @@ -39,5 +39,6 @@ func RunFix(fSys filesys.FileSystem) error { return err } + m.FixKustomizationPreMarshalling() return mf.Write(m) } diff --git a/kustomize/internal/commands/kustfile/kustomizationfile.go b/kustomize/internal/commands/kustfile/kustomizationfile.go index 900d748e2..f347e368a 100644 --- a/kustomize/internal/commands/kustfile/kustomizationfile.go +++ b/kustomize/internal/commands/kustfile/kustomizationfile.go @@ -170,7 +170,6 @@ func (mf *kustomizationFile) Write(kustomization *types.Kustomization) error { if kustomization == nil { return errors.New("util: kustomization file arg is nil") } - kustomization.FixKustomizationPreMarshalling() data, err := mf.marshal(kustomization) if err != nil { return err