Projectmanager: Fix context menu 'Project element' did not work

egw_links.js:66 Uncaught array of value needs a prefix
This commit is contained in:
nathan 2023-08-15 14:30:41 -06:00
parent 713a9b3a93
commit dd0780b29c

View File

@ -358,7 +358,7 @@ egw.extend('links', egw.MODULE_GLOBAL, function()
let name = name_val[0];
let val = name_val[1] || '';
if (val.indexOf('%26') !== -1) val = val.replace(/%26/g,'&'); // make sure to not double encode &
if (name.lastIndexOf('[]') == name.length-2)
if (name.lastIndexOf('[]') != -1 && name.lastIndexOf('[]') == name.length-2)
{
name = name.substr(0,name.length-2);
if (typeof vars[name] === 'undefined') vars[name] = [];