Skip to content

Commit

Permalink
replace filter_map with find_map
Browse files Browse the repository at this point in the history
  • Loading branch information
ecioppettini committed Jun 8, 2021
1 parent 3b70deb commit 819e108
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions explorer/src/db/mod.rs
Expand Up @@ -100,11 +100,10 @@ impl ExplorerDb {
block0
.contents
.iter()
.filter_map(|fragment| match fragment {
.find_map(|fragment| match fragment {
Fragment::Initial(config_params) => Some(config_params),
_ => None,
})
.next()
.expect("the Initial fragment to be present in the genesis block"),
);

Expand Down

0 comments on commit 819e108

Please sign in to comment.