From 4ab97f0fddc857b0978e64e0bcd501411515dc1f Mon Sep 17 00:00:00 2001 From: lrossett Date: Feb 11 2021 13:35:51 +0000 Subject: adding check for license header --- diff --git a/cli/koji_cli/commands.py b/cli/koji_cli/commands.py index 8b15979..1c6719d 100644 --- a/cli/koji_cli/commands.py +++ b/cli/koji_cli/commands.py @@ -3177,7 +3177,8 @@ def anon_handle_rpminfo(goptions, session, args): if not info.get('external_repo_id', 0): headers = session.getRPMHeaders(rpmID=info['id'], headers=["license"]) - print("License: %(license)s" % headers) + if 'license' in headers: + print("License: %(license)s" % headers) print("Build ID: %(build_id)s" % info) if info['buildroot_id'] is None: print("No buildroot data available")