Fix setChannel range check (#1495)

This commit is contained in:
Temm
2022-04-18 12:24:46 +02:00
committed by GitHub
parent 7d6f22c4e6
commit 02d5ad0d2a

View File

@@ -85,7 +85,7 @@ namespace wifi {
}
void setChannel(uint8_t ch) {
if ((ch < 1) && (ch > 14)) {
if ((ch < 1) || (ch > 14)) {
debuglnF("ERROR: Channel must be withing the range of 1-14");
} else {
ap_settings.channel = ch;