Skip to content

Commit

Permalink
Update ICDHandler.cpp
Browse files Browse the repository at this point in the history
  • Loading branch information
thivya-amazon authored Oct 27, 2023
1 parent 1df847e commit c5abbdf
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/app/icd/ICDHandler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ CHIP_ERROR CheckInMessageHandler::Init(Messaging::ExchangeManager * exchangeMana
{
VerifyOrReturnError(exchangeManager != nullptr, CHIP_ERROR_INVALID_ARGUMENT);
mExchangeManager = exchangeManager;
ReturnErrorOnFailure(exchangeManager->RegisterUnsolicitedMessageHandlerForType(MsgType::ICD_CheckInRx, this));
ReturnErrorOnFailure(exchangeManager->RegisterUnsolicitedMessageHandlerForType(Protocols::CheckIn::MsgType::ICD_CheckInRx, this));

return CHIP_NO_ERROR;
}
Expand All @@ -62,14 +62,14 @@ void CheckInMessageHandler::Shutdown()
// All timers(if used) need to be cleared here
if (mExchangeManager)
{
mExchangeManager->UnregisterUnsolicitedMessageHandlerForType(MsgType::ICD_CheckInRx);
mExchangeManager->UnregisterUnsolicitedMessageHandlerForType(Protocols::CheckIn::MsgType::ICD_CheckInRx);
mExchangeManager = NULL;
}
}
CHIP_ERROR CheckInMessageHandler::OnUnsolicitedMessageReceived(const PayloadHeader & payloadHeader, ExchangeDelegate *& newDelegate)
{
// Return error for wrong message type
if (!payloadHeader.HasMessageType(MsgType::ICD_CheckInRx))
if (!payloadHeader.HasMessageType(Protocols::CheckIn::MsgType::ICD_CheckInRx))
{
return CHIP_ERROR_INVALID_ARGUMENT;
}
Expand Down

0 comments on commit c5abbdf

Please sign in to comment.