From 9eef6df4fecbb17a65850337b79b565cc6da05bd Mon Sep 17 00:00:00 2001 From: ianballou Date: Thu, 4 Jan 2024 23:35:32 +0000 Subject: [PATCH] Fixes #37031 - hammer proxy content info fails when DB has no content counts --- lib/hammer_cli_katello/capsule.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/hammer_cli_katello/capsule.rb b/lib/hammer_cli_katello/capsule.rb index 28657973..7624771b 100644 --- a/lib/hammer_cli_katello/capsule.rb +++ b/lib/hammer_cli_katello/capsule.rb @@ -218,7 +218,7 @@ def extend_data(data) data["lifecycle_environments"].each do |lce| lce["content_views"].each do |cv| cv["repositories"].each do |repo| - if cv["up_to_date"] + if cv["up_to_date"] && !data.dig("content_counts").nil? cvv_count_repos = data.dig("content_counts", "content_view_versions", cv["cvv_id"].to_s, "repositories") cvv_count_repos.each do |_repo_id, counts_and_metadata|