Skip to content

Commit

Permalink
Fix parsing to handle when volume is a float (openhab#11151)
Browse files Browse the repository at this point in the history
Signed-off-by: Mark Hilbush <mark@hilbush.com>
  • Loading branch information
mhilbush authored and frederictobiasc committed Oct 26, 2021
1 parent c19ca3f commit 8e99635
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -646,7 +646,7 @@ private void handleMixerMessage(String mac, String[] messageParts) {
String volumeStringValue = decode(messageParts[3]);
updatePlayer(listener -> {
try {
int volume = Integer.parseInt(volumeStringValue);
int volume = Math.round(Float.parseFloat(volumeStringValue));

// Check if we received a relative volume change, or an absolute
// volume value.
Expand Down

0 comments on commit 8e99635

Please sign in to comment.