From 6d51c99851cccd7191c99778334c2425e9ae9b81 Mon Sep 17 00:00:00 2001 From: adrip-s73 Date: Mon, 20 Apr 2026 17:25:08 +0200 Subject: [PATCH] [18.0][FIX] web_m2x_options: prevent Owl crash when evaluateFieldBooleanOption receives an Array domain --- web_m2x_options/static/src/components/form.esm.js | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/web_m2x_options/static/src/components/form.esm.js b/web_m2x_options/static/src/components/form.esm.js index e2fbe9ca7bb0..32d3875dcabc 100644 --- a/web_m2x_options/static/src/components/form.esm.js +++ b/web_m2x_options/static/src/components/form.esm.js @@ -32,7 +32,13 @@ function evaluateHasCreatePermission(attrs) { } function evaluateFieldBooleanOption(option) { - return typeof option === "boolean" ? option : evaluateBooleanExpr(option); + if (typeof option === "boolean") { + return option; + } + if (typeof option === "string") { + return evaluateBooleanExpr(option); + } + return true; } patch(many2OneField, {