1
0
Fork 0
mirror of https://github.com/Zedfrigg/ironbar.git synced 2025-08-17 14:51:04 +02:00

fix(upower): avoid panic on client init error

This commit is contained in:
Jake Stanger 2024-08-09 23:16:00 +01:00
parent 9d125353c4
commit 474e1fe364
No known key found for this signature in database
GPG key ID: C51FC8F9CB0BEA61
4 changed files with 25 additions and 24 deletions

View file

@ -73,7 +73,7 @@ impl Module<gtk::Button> for UpowerModule {
) -> Result<()> {
let tx = context.tx.clone();
let display_proxy = context.client::<PropertiesProxy>();
let display_proxy = context.try_client::<PropertiesProxy>()?;
spawn(async move {
let mut prop_changed_stream = display_proxy.receive_properties_changed().await?;