[FIX] tools/safe_eval: Add missing builtin sorted

Before this commit, the function `sorted` wasn't available on
`safe_eval`, even though it's a Python built-in, which mades it
unavailable for Python-code evaluation, e.g. server actions.

After this commit, the above function is now accessible.

closes odoo/odoo#59715

X-original-commit: a725c8927963848c3f8ada3b71897a54b740cce6
Signed-off-by: Xavier Morel (xmo) <xmo@odoo.com>
This commit is contained in:
Luis González
2020-10-12 08:12:19 +00:00
parent ec3f5cdaf8
commit 6430ca499f
+1
View File
@@ -258,6 +258,7 @@ _BUILTINS = {
'sum': sum,
'reduce': functools.reduce,
'filter': filter,
'sorted': sorted,
'round': round,
'len': len,
'repr': repr,