diff --git a/extras/foreman_protector/dnf/foreman-protector.py b/extras/foreman_protector/dnf/foreman-protector.py index ff26241f4..54b672686 100644 --- a/extras/foreman_protector/dnf/foreman-protector.py +++ b/extras/foreman_protector/dnf/foreman-protector.py @@ -53,7 +53,7 @@ def _add_obsoletes(self): return final_query def sack(self): - if self.cli is not None and self.cli.command._basecmd not in PROTECT_COMMANDS: + if self.cli is not None and self.cli.command is not None and self.cli.command._basecmd not in PROTECT_COMMANDS: return if os.environ.get('LEAPP_IPU_IN_PROGRESS') is not None: return