From 30d53064b5e0f78a769dfe8e6702ea7e347a733f Mon Sep 17 00:00:00 2001 From: Stephen Wodecki Date: Sun, 2 Jul 2023 15:56:09 -0500 Subject: [PATCH] refactor --- pkg/storage/cacheable.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkg/storage/cacheable.go b/pkg/storage/cacheable.go index 5bf328b..3c112e6 100644 --- a/pkg/storage/cacheable.go +++ b/pkg/storage/cacheable.go @@ -71,10 +71,10 @@ func (c *CacheableStorage) Get(ctx context.Context, logicalPath string) (*Storag if err != nil { var nfError *NotFoundError // cache layer is expected to have missing records so let's only log other errors - if !errors.As(err, &nfError) { - logger.Error("cache", "miss", err.Error()) + if errors.As(err, &nfError) { + logger.Debug("cache", "miss", err.Error()) } else { - logger.Debug("cache", "error", err.Error()) + logger.Error("cache", "error", err.Error()) } }