diff options
author | Daniel Schadt <kingdread@gmx.de> | 2020-09-23 14:50:44 +0200 |
---|---|---|
committer | Daniel Schadt <kingdread@gmx.de> | 2020-09-23 14:50:44 +0200 |
commit | 8330abd3d42aadc30d1d819c9486c1341b4244c9 (patch) | |
tree | f38eaadd5c1e7bccb4ec5e78a284e243ad2b1212 /src/analyzers/helpers.rs | |
parent | b3090cd5687fd7c8f42e170883de87236c2f89cf (diff) | |
download | evtclib-8330abd3d42aadc30d1d819c9486c1341b4244c9.tar.gz evtclib-8330abd3d42aadc30d1d819c9486c1341b4244c9.tar.bz2 evtclib-8330abd3d42aadc30d1d819c9486c1341b4244c9.zip |
fix lints
Diffstat (limited to 'src/analyzers/helpers.rs')
-rw-r--r-- | src/analyzers/helpers.rs | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/analyzers/helpers.rs b/src/analyzers/helpers.rs index 674d752..b5042aa 100644 --- a/src/analyzers/helpers.rs +++ b/src/analyzers/helpers.rs @@ -29,10 +29,9 @@ pub fn boss_health(log: &Log) -> Option<u64> { /// Death is determined by checking for the [`EventKind::ChangeDead`][EventKind::ChangeDead] event, /// and whether a NPC is a boss is determined by the [`Log::is_boss`][Log::is_boss] method. pub fn boss_is_dead(log: &Log) -> bool { - log.events().iter().any(|ev| match ev.kind() { - EventKind::ChangeDead { agent_addr } if log.is_boss(*agent_addr) => true, - _ => false, - }) + log.events().iter().any( + |ev| matches!(ev.kind(), EventKind::ChangeDead { agent_addr } if log.is_boss(*agent_addr)), + ) } /// Checks whether the players exit combat after the boss. |