'11a': L.hasSystemFeature('hostapd', 'acs') ? [ 'auto', 'auto', true ] : []
};
- for (var i = 0; Array.isArray(data[1]) && i < data[1].length; i++)
+ for (var i = 0; i < data[1].length; i++)
this.channels[(data[1][i].mhz > 2484) ? '11a' : '11g'].push(
data[1][i].channel,
'%d (%d Mhz)'.format(data[1][i].channel, data[1][i].mhz),
if (vals[i+2])
sel.add(E('option', { value: vals[i+0] }, [ vals[i+1] ]));
- if (!isNaN(vals.selected))
+ if (vals && !isNaN(vals.selected))
sel.selectedIndex = vals.selected;
sel.parentNode.style.display = (sel.options.length <= 1) ? 'none' : '';