diff --git a/firewood/examples/rev.rs b/firewood/examples/rev.rs index 2f1c59878..b7d808232 100644 --- a/firewood/examples/rev.rs +++ b/firewood/examples/rev.rs @@ -180,7 +180,7 @@ impl RevisionTracker { fn get_revision(&self, index: usize) -> Revision { self.db .get_revision(&self.hashes[index], None) - .expect(&format!("revision-{index} should exist")) + .unwrap_or_else(|| panic!("revision-{index} should exist")) } }