Skip to content

Commit

Permalink
Merge pull request #582 from JulesDommartin/main
Browse files Browse the repository at this point in the history
Fixed wronge case for health access decoding
  • Loading branch information
roshanrajaratnam authored May 23, 2024
2 parents 124bb54 + 6123049 commit 848d040
Showing 1 changed file with 8 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,14 @@ private void parseAccessMessage(final AccessMessage message) {
}
mInternalTransportCallbacks.updateMeshNetwork(status);
mMeshStatusCallbacks.onMeshMessageReceived(message.getSrc(), status);
} else if (message.getOpCode() == ApplicationMessageOpCodes.HEALTH_CURRENT_STATUS) {
final HealthCurrentStatus healthCurrentStatus = new HealthCurrentStatus(message);
mInternalTransportCallbacks.updateMeshNetwork(healthCurrentStatus);
mMeshStatusCallbacks.onMeshMessageReceived(message.getSrc(), healthCurrentStatus);
} else if (message.getOpCode() == ApplicationMessageOpCodes.HEALTH_FAULT_STATUS) {
final HealthFaultStatus healthFaultStatus = new HealthFaultStatus(message);
mInternalTransportCallbacks.updateMeshNetwork(healthFaultStatus);
mMeshStatusCallbacks.onMeshMessageReceived(message.getSrc(), healthFaultStatus);
} else if (message.getOpCode() == ApplicationMessageOpCodes.SCENE_STATUS) {
final SceneStatus sceneStatus = new SceneStatus(message);
if (sceneStatus.isSuccessful()) {
Expand Down Expand Up @@ -500,14 +508,6 @@ private void parseAccessMessage(final AccessMessage message) {
final TimeZoneStatus timeZoneStatus = new TimeZoneStatus(message);
mInternalTransportCallbacks.updateMeshNetwork(timeZoneStatus);
mMeshStatusCallbacks.onMeshMessageReceived(message.getSrc(), timeZoneStatus);
} else if (message.getOpCode() == ApplicationMessageOpCodes.HEALTH_CURRENT_STATUS) {
final HealthCurrentStatus healthCurrentStatus = new HealthCurrentStatus(message);
mInternalTransportCallbacks.updateMeshNetwork(healthCurrentStatus);
mMeshStatusCallbacks.onMeshMessageReceived(message.getSrc(), healthCurrentStatus);
} else if (message.getOpCode() == ApplicationMessageOpCodes.HEALTH_FAULT_STATUS) {
final HealthFaultStatus healthFaultStatus = new HealthFaultStatus(message);
mInternalTransportCallbacks.updateMeshNetwork(healthFaultStatus);
mMeshStatusCallbacks.onMeshMessageReceived(message.getSrc(), healthFaultStatus);
} else if (message.getOpCode() == ApplicationMessageOpCodes.GENERIC_DEFAULT_TRANSITION_TIME_STATUS) {
final GenericDefaultTransitionTimeStatus genericDefaultTransitionTimeStatus = new GenericDefaultTransitionTimeStatus(message);
mInternalTransportCallbacks.updateMeshNetwork(genericDefaultTransitionTimeStatus);
Expand Down

0 comments on commit 848d040

Please sign in to comment.