From e5291ba16b554cf4b47f6e09afd64c0133b4ecde Mon Sep 17 00:00:00 2001 From: Max <1824153+tux-mind@users.noreply.github.com> Date: Mon, 10 Feb 2025 23:33:02 +0100 Subject: [PATCH] Log if app purchase was required and executed (#339) --- cmd/download.go | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/cmd/download.go b/cmd/download.go index b5fcccc3..c24e494b 100644 --- a/cmd/download.go +++ b/cmd/download.go @@ -30,6 +30,7 @@ func downloadCmd() *cobra.Command { var lastErr error var acc appstore.Account + var purchased bool = false return retry.Do(func() error { infoResult, err := dependencies.AppStore.AccountInfo() @@ -63,6 +64,10 @@ func downloadCmd() *cobra.Command { if err != nil { return err } + purchased = true + dependencies.Logger.Verbose(). + Bool("success", true). + Msg("purchase") } interactive, _ := cmd.Context().Value("interactive").(bool) @@ -96,6 +101,7 @@ func downloadCmd() *cobra.Command { dependencies.Logger.Log(). Str("output", out.DestinationPath). + Bool("purchased", purchased). Bool("success", true). Send()