Skip to content

Commit 14c1f5b

Browse files
[TMP] adapting ArduinoIotCloud to Cloud utils new encode/decode
1 parent c2504ea commit 14c1f5b

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/ArduinoIoTCloudDevice.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ int ArduinoCloudDevice::connected() {
4848
void ArduinoCloudDevice::handleMessage(Message *m) {
4949
_command = UnknownCmdId;
5050
if (m != nullptr) {
51-
_command = m->id;
51+
_command = static_cast<CommandId>(m->id);
5252
}
5353

5454
/* Run through the state machine. */

src/ArduinoIoTCloudThing.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ int ArduinoCloudThing::connected() {
6969
void ArduinoCloudThing::handleMessage(Message* m) {
7070
_command = UnknownCmdId;
7171
if (m != nullptr) {
72-
_command = m->id;
72+
_command = static_cast<CommandId>(m->id);
7373
if (_command == TimezoneCommandDownId) {
7474
_utcOffset = reinterpret_cast<TimezoneCommandDown*>(m)->params.offset;
7575
_utcOffsetExpireTime = reinterpret_cast<TimezoneCommandDown*>(m)->params.until;

0 commit comments

Comments
 (0)