From c9411fed6a89993f4966156d8ba3c2bfcd503b9b Mon Sep 17 00:00:00 2001 From: Andrew Date: Thu, 30 Jan 2025 21:12:35 +0000 Subject: [PATCH] [bluetooth_info.pl]: Print icon only if exists --- src/bluetooth_info.pl | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/bluetooth_info.pl b/src/bluetooth_info.pl index 7052655..bcf564e 100755 --- a/src/bluetooth_info.pl +++ b/src/bluetooth_info.pl @@ -16,4 +16,5 @@ my %icons = ( "audio-headset" => "" ); -printf("$icons{$icon} $device_name $battery_percentage%%"); +printf("$icons{$icon} ") if exists $icons{$icon}; +printf("$device_name $battery_percentage%%");