mirror of
https://gitlab.com/apparmor/apparmor
synced 2025-09-01 06:45:38 +00:00
Use extra_profiles.profile_exists()
... instead of accessing the internal storage directly.
This commit is contained in:
@@ -432,7 +432,7 @@ def create_new_profile(localfile, is_stub=False):
|
|||||||
def get_profile(prof_name):
|
def get_profile(prof_name):
|
||||||
"""search for inactive/extra profile, and ask if it should be used"""
|
"""search for inactive/extra profile, and ask if it should be used"""
|
||||||
|
|
||||||
if not extra_profiles.profiles.get(prof_name, False):
|
if not extra_profiles.profile_exists(prof_name):
|
||||||
return None # no inactive profile found
|
return None # no inactive profile found
|
||||||
|
|
||||||
# TODO: search based on the attachment, not (only?) based on the profile name
|
# TODO: search based on the attachment, not (only?) based on the profile name
|
||||||
|
Reference in New Issue
Block a user