mirror of
https://github.com/rust-lang/cargo.git
synced 2025-09-28 11:20:36 +00:00
Use expect over unwrap, for panic-in-panic aborts
... doesn't help, but it can't hurt either, right?
This commit is contained in:
parent
d27b47baf6
commit
b938637893
@ -682,7 +682,7 @@ impl Execs {
|
||||
self.expect_json = Some(
|
||||
expected
|
||||
.split("\n\n")
|
||||
.map(|obj| obj.parse().unwrap())
|
||||
.map(|line| line.parse().expect("line to be a valid JSON value"))
|
||||
.collect(),
|
||||
);
|
||||
self
|
||||
|
Loading…
x
Reference in New Issue
Block a user