simplify check to give precedence to ansible native modules

This commit is contained in:
Klaus Zerwes 2022-09-19 20:45:14 +02:00
parent 1557dea8e5
commit fa07744831

View File

@ -223,9 +223,7 @@ if not fqcnmapfile or args.updatefqcnmapfile:
fqcndict[nonfqcn] = []
if fqcn not in fqcndict[nonfqcn]:
# this defines the precedence of the replacements made
if fqcn.startswith('ansible.builtin.'):
fqcndict[nonfqcn].insert(0, fqcn)
elif fqcn.startswith('ansible.'):
if fqcn.startswith('ansible.'):
fqcndict[nonfqcn].insert(0, fqcn)
else:
fqcndict[nonfqcn].append(fqcn)