Skip to content

Commit 0187f09

Browse files
authored
HTTP client need WiFiClient
ESP8266HTTPClient.cpp has changed here esp8266/Arduino#7617 Regards
1 parent 13dc00b commit 0187f09

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

EasyDDNS.cpp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,8 +55,9 @@ void EasyDDNSClass::update(unsigned long ddns_update_interval){
5555
}
5656

5757
// ######## GET PUBLIC IP ######## //
58+
WiFiClient client;
5859
HTTPClient http;
59-
http.begin("http://ipv4bot.whatismyipaddress.com/");
60+
http.begin(client, "http://ipv4bot.whatismyipaddress.com/");
6061
int httpCode = http.GET();
6162
if(httpCode > 0) {
6263
if(httpCode == HTTP_CODE_OK) {
@@ -71,8 +72,9 @@ void EasyDDNSClass::update(unsigned long ddns_update_interval){
7172
// ######## CHECK & UPDATE ######### //
7273
if(old_ip != new_ip){
7374

75+
WiFiClient client;
7476
HTTPClient http;
75-
http.begin(update_url);
77+
http.begin(client, update_url);
7678
int httpCode = http.GET();
7779
if(httpCode > 0) {
7880
old_ip = new_ip;

0 commit comments

Comments
 (0)