We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 9589698 commit c65575eCopy full SHA for c65575e
src/lib.rs
@@ -428,9 +428,6 @@ fn cargo_build(matches: &ArgMatches, metadata: &Metadata) -> Result<Option<Artif
428
let messages = Message::parse_stream(stdout).collect::<Vec<_>>();
429
430
let status = child.wait()?;
431
- if !status.success() {
432
- bail!("Failed to parse crate metadata");
433
- }
434
435
let mut target_artifact: Option<Artifact> = None;
436
for message in messages {
@@ -457,6 +454,10 @@ fn cargo_build(matches: &ArgMatches, metadata: &Metadata) -> Result<Option<Artif
457
454
}
458
455
459
456
+ if !status.success() {
+ bail!("Failed to parse crate metadata");
+ }
460
+
461
if target_artifact.is_none() {
462
bail!("Could not determine the wanted artifact");
463
0 commit comments