From 207a5b7a6802313c215bfb4e8e0345f6ec8ba268 Mon Sep 17 00:00:00 2001 From: Tom5521 Date: Sat, 1 Mar 2025 15:44:51 -0300 Subject: [PATCH] refactor(po): rename header option functions for consistency - Renamed header option functions to follow a consistent naming convention by prefixing them with `HeaderWith`. - Updated all references to these functions in the codebase to use the new naming convention. - This change improves code readability and aligns with the project's naming standards. --- pkg/po/header_options.go | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/pkg/po/header_options.go b/pkg/po/header_options.go index d5f743b..26f82ac 100644 --- a/pkg/po/header_options.go +++ b/pkg/po/header_options.go @@ -2,43 +2,43 @@ package po type HeaderOption func(*HeaderConfig) -func WithHewaderConfig(c HeaderConfig) HeaderOption { +func HeaderWithConfig(c HeaderConfig) HeaderOption { return func(hc *HeaderConfig) { *hc = c } } -func WithNplurals(n uint) HeaderOption { +func HeaderWithNplurals(n uint) HeaderOption { return func(hc *HeaderConfig) { hc.Nplurals = n } } -func WithProjectIDVersion(v string) HeaderOption { +func HeaderWithProjectIDVersion(v string) HeaderOption { return func(hc *HeaderConfig) { hc.ProjectIDVersion = v } } -func WithReportMsgidBugsTo(r string) HeaderOption { +func HeaderWithReportMsgidBugsTo(r string) HeaderOption { return func(hc *HeaderConfig) { hc.ReportMsgidBugsTo = r } } -func WithLanguage(lang string) HeaderOption { +func HeaderWithLanguage(lang string) HeaderOption { return func(hc *HeaderConfig) { hc.Language = lang } } -func WithLanguageTeam(team string) HeaderOption { +func HeaderWithLanguageTeam(team string) HeaderOption { return func(hc *HeaderConfig) { hc.LanguageTeam = team } } -func WithLastTranslator(translator string) HeaderOption { +func HeaderWithLastTranslator(translator string) HeaderOption { return func(hc *HeaderConfig) { hc.LastTranslator = translator }