fix: unpair without changing the shade on the web server task

queueUnpairShade cleared shade->paired on the async_tcp task while loop()
owns the shade.  A second unpair queued before the first ran recorded
wasPaired=false and, if its Prog was refused, put back the wrong value.
The shade is now only changed by loop() once the Prog is queued, and the
response reports paired=false through a serializeShade overload instead.

No native test: Web.cpp can't be built by the native env.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
cjkas 2026-10-13 15:07:20 +02:00
parent 45776f64ce
commit ea520731a9
2 changed files with 10 additions and 16 deletions

View file

@ -36,7 +36,6 @@ struct web_command_t {
int8_t tiltPosition; // for setPositions/tilt
int8_t sunny; // for sensor
int8_t windy; // for sensor
bool wasPaired; // for unpair, restored if the Prog can't be sent
};
// Only setting positions never goes on air.