app/services/katello/pulp3/api/yum.rb in katello-4.12.1 vs app/services/katello/pulp3/api/yum.rb in katello-4.13.0.rc1

- old
+ new

@@ -30,9 +30,20 @@ def remotes_uln_api PulpRpmClient::RemotesUlnApi.new(api_client) end + def get_remotes_api(href: nil, url: nil) + fail 'Provide exactly one of href or url for yum remote selection!' if url.blank? && href.blank? + fail 'The href must be a pulp_rpm remote href!' if href && !href.start_with?('/pulp/api/v3/remotes/rpm/') + + if href&.start_with?('/pulp/api/v3/remotes/rpm/uln/') || url&.start_with?('uln') + remotes_uln_api + else + remotes_api + end + end + def copy_api PulpRpmClient::RpmCopyApi.new(api_client) end def content_package_groups_api