luci-app-mtwifi-cfg: check ifmode in handle remove

This commit is contained in:
hanwckf 2024-01-13 23:43:50 +08:00
parent 3791aab06d
commit d71a790778

View File

@ -2011,9 +2011,10 @@ return view.extend({
s.handleRemove = function(section_id, radioNet, ev) {
var radioName = radioNet.getWifiDeviceName();
var ifmode = radioNet.getMode();
var hwtype = uci.get('wireless', radioName, 'type');
if (hwtype == 'mtwifi')
if (hwtype == 'mtwifi' && ifmode == 'ap')
{
var wifi_sections = uci.sections('wireless', 'wifi-iface');
var mbssid_num = 0;