Skip to content
Snippets Groups Projects
Commit 6acb885e authored by Rob Swindell's avatar Rob Swindell :speech_balloon:
Browse files

Merge branch 'ddmr_cfg_format_value_undefined_fix' into 'master'

ddmr_cfg.js: Added a type check that should fix an 'undefined' error when formatting option values

See merge request main/sbbs!365
parents ba84e207 ff291491
No related branches found
No related tags found
2 merge requests!463MRC mods by Codefenix (2024-10-20),!365ddmr_cfg.js: Added a type check that should fix an 'undefined' error when formatting option values
......@@ -288,7 +288,10 @@ function formatCfgMenuText(pItemTextMaxLen, pItemText, pVal)
if (valType === "boolean")
value = pVal ? "Yes" : "No";
else
value = pVal.toString();
{
if (typeof(pVal) !== "undefined")
value = pVal.toString();
}
return format(formatCfgMenuText.formatStr, pItemText.substr(0, pItemTextMaxLen), value);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment