Skip to content

Commit

Permalink
[utils/create_scap_delta_tailoring.py] Fix case where the profile was…
Browse files Browse the repository at this point in the history
… not found

Before this a call on None would cause the script to error out.
  • Loading branch information
Mab879 committed Sep 26, 2023
1 parent e01bebb commit 71b4588
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions utils/create_scap_delta_tailoring.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ def get_profile(product, profile_name):
for profile in profiles:
if profile.attrib['id'] == profile_name_fqdn:
return profile
raise ValueError("Profile %s was not found." % profile_name_fqdn)


get_profile.__annotations__ = {'product': str, 'profile_name': str, 'return': ET.Element}
Expand Down

0 comments on commit 71b4588

Please sign in to comment.