mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-07 22:02:50 +00:00
Fix IOS TypeError * if flags are None, then ' '.join(flags) fails * fixed get_defaults_flag so that it returns a list, and ignores lines with white space Fixes #26918
This commit is contained in:
committed by
Toshio Kuratomi
parent
0b5b5ec50a
commit
9f64e446c6
@@ -71,13 +71,13 @@ def get_defaults_flag(module):
|
||||
|
||||
commands = set()
|
||||
for line in out.splitlines():
|
||||
if line:
|
||||
if line.strip():
|
||||
commands.add(line.strip().split()[0])
|
||||
|
||||
if 'all' in commands:
|
||||
return 'all'
|
||||
return ['all']
|
||||
else:
|
||||
return 'full'
|
||||
return ['full']
|
||||
|
||||
|
||||
def get_config(module, flags=[]):
|
||||
|
||||
Reference in New Issue
Block a user