mirror of
https://github.com/esphome/esphome.git
synced 2026-05-24 09:56:46 +08:00
[nextion] Use std::string::starts_with for HTTPS URL check (#16090)
This commit is contained in:
@@ -331,7 +331,7 @@ bool Nextion::upload_tft(uint32_t baud_rate, bool exit_reparse) {
|
||||
|
||||
#ifdef USE_ESP8266
|
||||
WiFiClient *Nextion::get_wifi_client_() {
|
||||
if (this->tft_url_.compare(0, 6, "https:") == 0) {
|
||||
if (this->tft_url_.starts_with("https:")) {
|
||||
if (this->wifi_client_secure_ == nullptr) {
|
||||
// NOLINTNEXTLINE(cppcoreguidelines-owning-memory)
|
||||
this->wifi_client_secure_ = new BearSSL::WiFiClientSecure();
|
||||
|
||||
Reference in New Issue
Block a user