diff --git a/plugin/SqueezeESP32/Player.pm b/plugin/SqueezeESP32/Player.pm index cb455c7fd..603c52d2b 100644 --- a/plugin/SqueezeESP32/Player.pm +++ b/plugin/SqueezeESP32/Player.pm @@ -220,7 +220,8 @@ sub send_equalizer { sub send_loudness { my ($client, $loudness) = @_; - $loudness ||= $prefs->client($client)->get('loudness') || 0; + $loudness = defined $loudness ? $loudness : $prefs->client($client)->get('loudness'); + my $data = pack("c1", $loudness); $client->sendFrame( loud => \$data ); }