File tree 1 file changed +7
-13
lines changed
1 file changed +7
-13
lines changed Original file line number Diff line number Diff line change @@ -78,19 +78,13 @@ async fn power_up_and_wait_for_connection(
78
78
connect : Option < Address > ,
79
79
) -> Result < ( BluetoothState , Stream ) > {
80
80
// setting BT alias for further use
81
- let alias: String ;
82
-
83
- match btalias {
84
- None => {
85
- alias = match get_cpu_serial_number_suffix ( ) . await {
86
- Ok ( suffix) => format ! ( "{}-{}" , BT_ALIAS , suffix) ,
87
- Err ( _) => String :: from ( BT_ALIAS ) ,
88
- } ;
89
- }
90
- Some ( btalias) => {
91
- alias = btalias;
92
- }
93
- }
81
+ let alias = match btalias {
82
+ None => match get_cpu_serial_number_suffix ( ) . await {
83
+ Ok ( suffix) => format ! ( "{}-{}" , BT_ALIAS , suffix) ,
84
+ Err ( _) => String :: from ( BT_ALIAS ) ,
85
+ } ,
86
+ Some ( btalias) => btalias,
87
+ } ;
94
88
info ! ( "{} 🥏 Bluetooth alias: <bold><green>{}</>" , NAME , alias) ;
95
89
96
90
let session = bluer:: Session :: new ( ) . await ?;
You can’t perform that action at this time.
0 commit comments