Fix xdg-open for Trash (#2547)

* fix Trash not opening

* remove unnecessary unwrap

* fix formatting errors
This commit is contained in:
Gedeon 2024-06-11 12:23:06 -04:00 committed by GitHub
parent 0cd993c699
commit a88a9db5f0
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -156,7 +156,7 @@ async fn open_trash_in_os_explorer() -> Result<(), ()> {
#[cfg(target_os = "linux")]
{
Command::new("xdg-open")
.arg("~/.local/share/Trash/")
.arg("trash://")
.spawn()
.map_err(|err| error!("Error opening trash: {err:#?}"))?
.wait()