From 3c32b810d51586fe3c988c81e7ad377804e11b5b Mon Sep 17 00:00:00 2001 From: dmaes Date: Fri, 8 Apr 2022 12:23:51 +0200 Subject: [PATCH] fix tabs/spaces --- registry/tasks.go | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/registry/tasks.go b/registry/tasks.go index 5d9e7e0..6086894 100644 --- a/registry/tasks.go +++ b/registry/tasks.go @@ -86,11 +86,11 @@ func PurgeOldTags(client *Client, purgeDryRun bool, purgeTagsKeepDays, purgeTags // Filter out tags by retention days and regexp for _, tag := range repos[repo] { - regexpKeep := false - if purgeTagsKeepRegexp != "" { - regexpMatch, _ := regexp.MatchString(purgeTagsKeepRegexp, tag.name) - regexpKeep = regexpMatch - } + regexpKeep := false + if purgeTagsKeepRegexp != "" { + regexpMatch, _ := regexp.MatchString(purgeTagsKeepRegexp, tag.name) + regexpKeep = regexpMatch + } delta := int(now.Sub(tag.created).Hours() / 24) if !regexpKeep && delta > purgeTagsKeepDays { purgeTags[repo] = append(purgeTags[repo], tag.name)