From 52d03768309dff610197b46968e156b25d9b5c34 Mon Sep 17 00:00:00 2001 From: Pavel Okhlopkov Date: Thu, 24 Oct 2024 16:14:09 +0300 Subject: [PATCH] Logger in hook public Signed-off-by: Pavel Okhlopkov --- pkg/hook/hook.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkg/hook/hook.go b/pkg/hook/hook.go index 7f74fda2..903ade67 100644 --- a/pkg/hook/hook.go +++ b/pkg/hook/hook.go @@ -46,7 +46,7 @@ type Hook struct { TmpDir string - logger *unilogger.Logger + Logger *unilogger.Logger } func NewHook(name, path string, logger *unilogger.Logger) *Hook { @@ -54,7 +54,7 @@ func NewHook(name, path string, logger *unilogger.Logger) *Hook { Name: name, Path: path, Config: &config.HookConfig{}, - logger: logger, + Logger: logger, } } @@ -142,7 +142,7 @@ func (h *Hook) Run(_ BindingType, context []BindingContext, logLabels map[string result := &Result{} - result.Usage, err = executor.RunAndLogLines(hookCmd, logLabels, h.logger) + result.Usage, err = executor.RunAndLogLines(hookCmd, logLabels, h.Logger) if err != nil { return result, fmt.Errorf("%s FAILED: %s", h.Name, err) }