wifi networks: improve notifications

This commit is contained in:
end-4
2025-03-28 19:01:41 +01:00
parent f2ad19f14b
commit e99321c5f2
@@ -216,10 +216,14 @@ const CurrentNetwork = () => {
if (activeSSID) { if (activeSSID) {
execAsync(['nmcli', 'connection', 'delete', activeSSID]) execAsync(['nmcli', 'connection', 'delete', activeSSID])
.catch(err => Utils.notify(`Failed to forget network: ${err}`)); .catch(err => Utils.execAsync(['notify-send',
"Network",
`Failed to forget network - Hold to copy\n${err}`,
'-a', 'ags',
]).catch(print));
} }
}) })
.catch(print); .catch();
}, },
setup: setupCursorHover, setup: setupCursorHover,
}); });
@@ -233,9 +237,11 @@ const CurrentNetwork = () => {
Utils.execAsync(`nm-connection-editor --edit ${uuid.trim()}`); Utils.execAsync(`nm-connection-editor --edit ${uuid.trim()}`);
} }
closeEverything(); closeEverything();
}).catch(error => { }).catch(err => Utils.execAsync(['notify-send',
Utils.notify('Failed to get connection UUID'); "Network",
}); `Failed to get connection UUID - Hold to copy\n${err}`,
'-a', 'ags',
]).catch(print));
}, },
setup: setupCursorHover, setup: setupCursorHover,
}); });