fuck is some bullshit ts returns cuh
This commit is contained in:
1 parent
00cf33eefb
commit
fc6548e15c
6 files changed
+34
-15
No files matched your search
@@ -32,7 +32,7 @@ pub async fn get(dev: Option<&str>) -> anyhow::Result<Vec<AddrOutput>> {
|
||||
anyhow::bail!(String::from_utf8_lossy(&output.stderr).into_owned());
|
||||
}
|
||||
|
||||
Ok(serde_json::from_slice(&output.stdout)?)
|
||||
serde_json::from_slice(&output.stdout).context("Deserialize failed")
|
||||
}
|
||||
pub async fn _get(dev: Option<&str>) -> io::Result<Output> {
|
||||
let mut cmd = tokio::process::Command::new("ip");
|
||||
|
||||
@@ -24,7 +24,7 @@ pub async fn get(
|
||||
if !output.status.success() {
|
||||
bail!(String::from_utf8_lossy(&output.stderr).into_owned())
|
||||
} else {
|
||||
Ok(serde_json::from_slice(&output.stdout)?)
|
||||
serde_json::from_slice(&output.stdout).context("Deserialize failed")
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user