mirror of
https://github.com/lucaspalomodevelop/core.git
synced 2026-03-13 08:09:41 +00:00
interfaces: adjust wireless handling slightly for new return code
This commit is contained in:
parent
9c1342dac9
commit
2396e4b3ff
@ -952,7 +952,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'GET') {
|
||||
if ($clone_count > 1) {
|
||||
$wlanif = get_real_interface($if);
|
||||
$a_interfaces[$if]['wireless']['mode'] = $pconfig['mode'];
|
||||
if (!_interfaces_wlan_clone("{$wlanif}_", $a_interfaces[$if])) {
|
||||
if (empty(_interfaces_wlan_clone("{$wlanif}_", $a_interfaces[$if]))) {
|
||||
$input_errors[] = sprintf(gettext("Unable to change mode to %s. You may already have the maximum number of wireless clones supported in this mode."), $wlan_modes[$a_interfaces[$if]['wireless']['mode']]);
|
||||
} else {
|
||||
legacy_interface_destroy("{$wlanif}_");
|
||||
|
||||
@ -101,7 +101,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'GET') {
|
||||
}
|
||||
}
|
||||
if (count($input_errors) == 0) {
|
||||
if (!_interfaces_wlan_clone($clone['cloneif'], $clone)) {
|
||||
if (empty(_interfaces_wlan_clone($clone['cloneif'], $clone))) {
|
||||
$input_errors[] = sprintf(gettext('Error creating interface with mode %s. The %s interface may not support creating more clones with the selected mode.'), $wlan_modes[$clone['mode']], $clone['if']);
|
||||
} else {
|
||||
if (isset($id)) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user