Keep download count on Container tag overwrite (#20728) (#20735)

Co-authored-by: 6543 <6543@obermui.de>
This commit is contained in:
KN4CK3Rand6543 authored and GitHub committed 2022-08-09 17:33:45 +02:00
1 parent 9ec1c8812e
commit 113d13a026
2 files changed
+16 -1

No files matched your search

@@ -312,6 +312,9 @@ func createPackageAndVersion(ctx context.Context, mci *manifestCreationInfo, met
return nil, err
}
// keep download count on overwrite
_pv.DownloadCount = pv.DownloadCount
if pv, err = packages_model.GetOrInsertVersion(ctx, _pv); err != nil {
log.Error("Error inserting package: %v", err)
return nil, err