Cleaning up use of literal_eval in basic.py AnsibleModule.safe_eval
This commit is contained in:
parent
cc7867d1de
commit
0e68c6d6fe
1 changed files with 1 additions and 5 deletions
|
@ -1263,11 +1263,7 @@ class AnsibleModule(object):
|
||||||
return (str, None)
|
return (str, None)
|
||||||
return str
|
return str
|
||||||
try:
|
try:
|
||||||
result = None
|
result = literal_eval(str)
|
||||||
if not locals:
|
|
||||||
result = literal_eval(str)
|
|
||||||
else:
|
|
||||||
result = literal_eval(str, None, locals)
|
|
||||||
if include_exceptions:
|
if include_exceptions:
|
||||||
return (result, None)
|
return (result, None)
|
||||||
else:
|
else:
|
||||||
|
|
Loading…
Reference in a new issue