luci-mod-system: Set description to blank if the trigger has none

In this case the cbi description div will not be generated and when
switching to another trigger later, attempts to change the description
div contents will fail.

Signed-off-by: Florian Eckert <fe@dev.tdt.de>
(cherry picked from commit 3de5446003)
This commit is contained in:
Florian Eckert 2022-04-12 10:05:34 +02:00
parent 0e4eeeb9a2
commit ba7d0c7ddd

View file

@ -89,7 +89,7 @@ return view.extend({
var plugin = plugins[i];
if ( plugin.name === value )
this.map.findElement('id', 'cbid.system.%s.trigger'.format(section))
.nextElementSibling.innerHTML = plugin.form.description || '';
.nextElementSibling.innerHTML = plugin.form.description || ' ';
}
}
o.load = function(section_id) {