From 90d57846f937fd7b85219741a012abdd93d6936c Mon Sep 17 00:00:00 2001 From: Amariah Kamau <110414493+AmariahAK@users.noreply.github.com> Date: Mon, 20 Jul 2026 17:42:24 +0300 Subject: [PATCH] fix(package): rename t back to epoch in StampModTimes for self-documentation Parameter `t` renamed to `epoch` in Chart.StampModTimes() as requested by reviewer: the `epoch` name is self-documenting. Co-authored-by: atlarix-agent Signed-off-by: Amariah Kamau <110414493+AmariahAK@users.noreply.github.com> --- pkg/chart/v2/chart.go | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/pkg/chart/v2/chart.go b/pkg/chart/v2/chart.go index 65c594603..653ecbf22 100644 --- a/pkg/chart/v2/chart.go +++ b/pkg/chart/v2/chart.go @@ -179,33 +179,33 @@ func (ch *Chart) CRDObjects() []CRD { // StampModTimes sets timestamps on the chart (and dependencies) to epoch. // This is used for reproducible builds via SOURCE_DATE_EPOCH. -func (ch *Chart) StampModTimes(t time.Time) { - t = t.UTC().Truncate(time.Second) - ch.ModTime = t +func (ch *Chart) StampModTimes(epoch time.Time) { + epoch = epoch.UTC().Truncate(time.Second) + ch.ModTime = epoch if len(ch.Schema) > 0 { - ch.SchemaModTime = t + ch.SchemaModTime = epoch } if ch.Lock != nil { - ch.Lock.Generated = t + ch.Lock.Generated = epoch } for _, f := range ch.Raw { if f != nil { - f.ModTime = t + f.ModTime = epoch } } for _, f := range ch.Templates { if f != nil { - f.ModTime = t + f.ModTime = epoch } } for _, f := range ch.Files { if f != nil { - f.ModTime = t + f.ModTime = epoch } } for _, dep := range ch.Dependencies() { - dep.StampModTimes(t) + dep.StampModTimes(epoch) } }