Skip to content

Commit 7af47a3

Browse files
dagwieersbcoca
authored andcommitted
Rename function bool() as it is a Python built-in function (ansible#15651)
1 parent f2980fc commit 7af47a3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/ansible/plugins/filter/core.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ def to_nice_json(a, *args, **kw):
106106
# Fallback to the to_json filter
107107
return to_json(a, *args, **kw)
108108

109-
def bool(a):
109+
def to_bool(a):
110110
''' return a bool for the arg '''
111111
if a is None or type(a) == bool:
112112
return a
@@ -431,7 +431,7 @@ def filters(self):
431431
'win_splitdrive': partial(unicode_wrap, ntpath.splitdrive),
432432

433433
# value as boolean
434-
'bool': bool,
434+
'bool': to_bool,
435435

436436
# quote string for shell usage
437437
'quote': quote,

0 commit comments

Comments
 (0)