File tree 2 files changed +8
-6
lines changed
2 files changed +8
-6
lines changed Original file line number Diff line number Diff line change @@ -39,10 +39,11 @@ void setup() {
39
39
40
40
// by default DNSServer is started serving any "*" domain name. It will reply
41
41
// AccessPoint's IP to all DNS request (this is required for Captive Portal detection)
42
- if ( dnsServer.start () )
42
+ if (dnsServer.start ()) {
43
43
Serial.println (" Started DNS server in captive portal-mode" );
44
- else
44
+ } else {
45
45
Serial.println (" Err: Can't start DNS server!" );
46
+ }
46
47
47
48
// serve a simple root page
48
49
server.on (" /" , handleRoot);
Original file line number Diff line number Diff line change @@ -22,11 +22,12 @@ bool DNSServer::start() {
22
22
#if SOC_WIFI_SUPPORTED
23
23
if (WiFi.getMode () & WIFI_AP) {
24
24
_resolvedIP = WiFi.softAPIP ();
25
- } else
26
- return false ; // won't run if WiFi is not in AP mode, or no WiFi
25
+ } else {
26
+ return false ; // won't run if WiFi is not in AP mode, or no WiFi
27
+ }
27
28
#else
28
- return false ; // for other non WiFi-AP networking an overloaded method must be used to get device's IP
29
- // start(uint16_t port, const String &domainName, const IPAddress &resolvedIP)
29
+ return false ; // for other non WiFi-AP networking an overloaded method must be used to get device's IP
30
+ // start(uint16_t port, const String &domainName, const IPAddress &resolvedIP)
30
31
#endif
31
32
}
32
33
You can’t perform that action at this time.
0 commit comments