Added error code -100
This commit is contained in:
parent
56cd730ad4
commit
891794af7c
@ -148,6 +148,8 @@
|
||||
appendLog( "Push target 'mqtt' failed with error timeout" );
|
||||
else if(code==-10)
|
||||
appendLog( "Push target 'mqtt' failed with error denied" );
|
||||
else if(code==-100)
|
||||
appendLog( "Push target 'mqtt' skipped since it's using SSL" );
|
||||
else
|
||||
appendLog( "Push target 'mqtt' failed with error code " + code );
|
||||
}
|
||||
@ -177,6 +179,8 @@
|
||||
appendLog( "Push target 'influxdb' failed with error code 401, unauthorized" );
|
||||
else if(code==404)
|
||||
appendLog( "Push target 'influxdb' failed with error code 404, url not found" );
|
||||
else if(code==-100)
|
||||
appendLog( "Push target 'influxdb' skipped since it's using SSL" );
|
||||
else
|
||||
appendLog( "Push target 'influxdb' failed with error code " + code );
|
||||
}
|
||||
@ -206,6 +210,8 @@
|
||||
appendLog( "Push target '" + target + "' failed with error code 401, unauthorized" );
|
||||
else if(code==404)
|
||||
appendLog( "Push target '" + target + "' failed with error code 404, url not found" );
|
||||
else if(code==-100)
|
||||
appendLog( "Push target '" + target + "' skipped since it's using SSL" );
|
||||
else
|
||||
appendLog( "Push target '" + target + "' failed with error code " + code );
|
||||
}
|
||||
|
File diff suppressed because one or more lines are too long
@ -204,10 +204,13 @@ void PushTarget::sendInfluxDb2(TemplatingEngine& engine, bool isSecure) {
|
||||
String auth = "Token " + String(myConfig.getInfluxDb2PushToken());
|
||||
|
||||
if (isSecure) {
|
||||
#if defined( ESP8266 )
|
||||
if (runMode == RunMode::configurationMode) {
|
||||
Log.notice(F("PUSH: Skipping InfluxDB since SSL is enabled and we are in config mode." CR));
|
||||
_lastCode = -100;
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
|
||||
Log.notice(F("PUSH: InfluxDB, SSL enabled without validation." CR));
|
||||
_wifiSecure.setInsecure();
|
||||
@ -290,10 +293,13 @@ void PushTarget::sendHttpPost(TemplatingEngine& engine, bool isSecure,
|
||||
#endif
|
||||
|
||||
if (isSecure) {
|
||||
#if defined( ESP8266 )
|
||||
if (runMode == RunMode::configurationMode) {
|
||||
Log.notice(F("PUSH: Skipping HTTP since SSL is enabled and we are in config mode." CR));
|
||||
_lastCode = -100;
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
|
||||
Log.notice(F("PUSH: HTTP, SSL enabled without validation." CR));
|
||||
_wifiSecure.setInsecure();
|
||||
@ -364,10 +370,13 @@ void PushTarget::sendHttpGet(TemplatingEngine& engine, bool isSecure) {
|
||||
#endif
|
||||
|
||||
if (isSecure) {
|
||||
#if defined( ESP8266 )
|
||||
if (runMode == RunMode::configurationMode) {
|
||||
Log.notice(F("PUSH: Skipping HTTP since SSL is enabled and we are in config mode." CR));
|
||||
_lastCode = -100;
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
|
||||
Log.notice(F("PUSH: HTTP, SSL enabled without validation." CR));
|
||||
_wifiSecure.setInsecure();
|
||||
@ -415,10 +424,13 @@ void PushTarget::sendMqtt(TemplatingEngine& engine, bool isSecure) {
|
||||
int port = myConfig.getMqttPort();
|
||||
|
||||
if (myConfig.isMqttSSL()) {
|
||||
#if defined( ESP8266 )
|
||||
if (runMode == RunMode::configurationMode) {
|
||||
Log.notice(F("PUSH: Skipping MQTT since SSL is enabled and we are in config mode." CR));
|
||||
_lastCode = -100;
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
|
||||
Log.notice(F("PUSH: MQTT, SSL enabled without validation." CR));
|
||||
_wifiSecure.setInsecure();
|
||||
|
Loading…
Reference in New Issue
Block a user