From 504060602e4a7ab90de5414a77f697ad605e6053 Mon Sep 17 00:00:00 2001 From: Partha Aji Date: Wed, 28 Aug 2019 15:18:53 -0400 Subject: [PATCH] Fixes #27729 - Upload rpm without --content-type (#690) hammer repository upload-content --id=245 --path ./t.rpm This command failed with `undefined local variable or method `option_content_type` This commit addresses this issue (cherry picked from commit d4a88c8a37db5f0798f3031bccf428e7f8dba898) --- lib/hammer_cli_katello/repository.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/hammer_cli_katello/repository.rb b/lib/hammer_cli_katello/repository.rb index 10df9af1..c8321ddb 100644 --- a/lib/hammer_cli_katello/repository.rb +++ b/lib/hammer_cli_katello/repository.rb @@ -443,9 +443,9 @@ def import_uploads(uploads, opts = {}) params = {:id => get_identifier, :uploads => uploads, publish_repository: publish_repository, - sync_capsule: sync_capsule, - content_type: option_content_type + sync_capsule: sync_capsule } + params[:content_type] = options["option_content_type"] if options["option_content_type"] resource.call(:import_uploads, params) end