mirror of
https://github.com/ansible-collections/community.general.git
synced 2024-09-14 20:13:21 +02:00
flatpak_remote: Handle empty output in remote_exists (#52010)
`flatpak remote-list -d` can return an empty output on Fedora 29 (version 1.2.0).
This commit is contained in:
parent
686f4b35e3
commit
fcb6f136cd
1 changed files with 2 additions and 0 deletions
|
@ -169,6 +169,8 @@ def remote_exists(module, binary, name, method):
|
||||||
output = _flatpak_command(module, False, command)
|
output = _flatpak_command(module, False, command)
|
||||||
for line in output.splitlines():
|
for line in output.splitlines():
|
||||||
listed_remote = line.split()
|
listed_remote = line.split()
|
||||||
|
if len(listed_remote) == 0:
|
||||||
|
continue
|
||||||
if listed_remote[0] == to_native(name):
|
if listed_remote[0] == to_native(name):
|
||||||
return True
|
return True
|
||||||
return False
|
return False
|
||||||
|
|
Loading…
Reference in a new issue