summaryrefslogtreecommitdiff
path: root/src/steps.rs
diff options
context:
space:
mode:
authorLars Wirzenius <liw@liw.fi>2019-12-14 16:49:46 +0200
committerLars Wirzenius <liw@liw.fi>2019-12-14 16:49:46 +0200
commita79b7f1752622366ba3ef84b1b9b94404cbbbd9f (patch)
tree26bd9b69d559d0638a8056374e3d35431e17b185 /src/steps.rs
parent2be57a8258be1496939bc198e7e4016c37887f62 (diff)
downloadsubplot-a79b7f1752622366ba3ef84b1b9b94404cbbbd9f.tar.gz
Refactor: use ? for error result return
Diffstat (limited to 'src/steps.rs')
-rw-r--r--src/steps.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/steps.rs b/src/steps.rs
index 7fbb8a8..3453e9c 100644
--- a/src/steps.rs
+++ b/src/steps.rs
@@ -45,7 +45,7 @@ impl ScenarioStep {
Some("given") => StepKind::Given,
Some("when") => StepKind::When,
Some("then") => StepKind::Then,
- _ => return Err(Error::UnknownStepKind),
+ _ => Err(Error::UnknownStepKind)?,
};
let mut joined = String::new();