Serialize the uci list value into a space separated string before passing
it to String.format() for HTML escaping. Without that change, empty strings
were returned whenever the underlying uci get operation yieled an array.
Fixes: #4993
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
(cherry picked from commit
5c792aefc744d1417fc9e24cfb92cd61cf8a651f)
if (cval == null)
cval = this.default;
+ if (Array.isArray(cval))
+ cval = cval.join(' ');
+
return (cval != null) ? '%h'.format(cval) : null;
},