diff --git a/lib/ansible/modules/packaging/os/flatpak_remote.py b/lib/ansible/modules/packaging/os/flatpak_remote.py index e77c41eabb..db208f1bd9 100644 --- a/lib/ansible/modules/packaging/os/flatpak_remote.py +++ b/lib/ansible/modules/packaging/os/flatpak_remote.py @@ -169,6 +169,8 @@ def remote_exists(module, binary, name, method): output = _flatpak_command(module, False, command) for line in output.splitlines(): listed_remote = line.split() + if len(listed_remote) == 0: + continue if listed_remote[0] == to_native(name): return True return False