mirror of
https://github.com/esphome/esphome.git
synced 2024-11-23 15:38:11 +01:00
only activate WiFiClientSecure when skip cert true
This commit is contained in:
parent
27865935fe
commit
70b54ab422
1 changed files with 2 additions and 1 deletions
|
@ -401,7 +401,8 @@ async def to_code(config):
|
|||
cg.add(var.set_ssl_fingerprint(arr))
|
||||
|
||||
if CONF_SKIP_CERT_CN_CHECK in config:
|
||||
cg.add_define("USE_MQTT_SECURE_CLIENT")
|
||||
if config[CONF_SKIP_CERT_CN_CHECK]:
|
||||
cg.add_define("USE_MQTT_SECURE_CLIENT")
|
||||
cg.add(var.set_skip_cert_cn_check(config[CONF_SKIP_CERT_CN_CHECK]))
|
||||
|
||||
if CONF_CERTIFICATE_AUTHORITY in config:
|
||||
|
|
Loading…
Reference in a new issue