Commit c85aac8b by Deon Bredenhann

Treat a False mandatory variable as defined.

parent 4f1f13b1
......@@ -76,8 +76,11 @@ def skipped(*a, **kw):
def mandatory(a):
''' Make a variable mandatory '''
if not a:
try:
a
except NameError:
raise errors.AnsibleFilterError('Mandatory variable not defined.')
else:
return a
def bool(a):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment