Skip to content

Commit

Permalink
Apply suggestions about endpoint id from code review
Browse files Browse the repository at this point in the history
  • Loading branch information
bzbarsky-apple committed Oct 12, 2021
1 parent 342381b commit c2f16b5
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ bool emberAfBarrierControlClusterBarrierControlGoToPercentCallback(
{
auto & percentOpen = commandData.percentOpen;

EndpointId endpoint = emberAfCurrentCommand()->apsFrame->destinationEndpoint;
EndpointId endpoint = commandPath.mEndpointId;
EmberAfStatus status = EMBER_ZCL_STATUS_SUCCESS;

emberAfBarrierControlClusterPrintln("RX: GoToPercentCallback p=%d", percentOpen);
Expand Down Expand Up @@ -349,7 +349,7 @@ bool emberAfBarrierControlClusterBarrierControlStopCallback(app::CommandHandler
const app::ConcreteCommandPath & commandPath,
const Commands::BarrierControlStop::DecodableType & commandData)
{
EndpointId endpoint = emberAfCurrentCommand()->apsFrame->destinationEndpoint;
EndpointId endpoint = commandPath.mEndpointId;
emberAfDeactivateServerTick(endpoint, BarrierControl::Id);
setMovingState(endpoint, EMBER_ZCL_BARRIER_CONTROL_MOVING_STATE_STOPPED);
sendDefaultResponse(EMBER_ZCL_STATUS_SUCCESS);
Expand Down

0 comments on commit c2f16b5

Please sign in to comment.