Merge pull request #6303 from s-hadinger/fix_echo_2nd_gen

Fix Unrecognized relay with Echo Dot 2nd Gen
This commit is contained in:
Theo Arends 2019-08-27 22:24:44 +02:00 committed by GitHub
commit 3048b6550c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -406,6 +406,9 @@ uint32_t findEchoGeneration(void) {
break;
}
}
if (0 == user_agent.length()) {
gen = 1; // if no user-agent, also revert to gen v1
}
AddLog_P2(LOG_LEVEL_DEBUG_MORE, D_LOG_HTTP D_HUE " User-Agent: %s, gen=%d", user_agent.c_str(), gen); // Header collection is set in xdrv_01_webserver.ino, in StartWebserver()