diff options
Diffstat (limited to 'src/main.rs')
-rw-r--r-- | src/main.rs | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/main.rs b/src/main.rs index 85018c8..9d98cc9 100644 --- a/src/main.rs +++ b/src/main.rs @@ -232,9 +232,11 @@ fn search_log(entry: &DirEntry, opt: &Opt) -> Result<Option<LogResult>, RuntimeE /// Extract human-readable information from the given log file. fn extract_info(entry: &DirEntry, log: &Log) -> LogResult { - let boss_name = match log.boss().name() { - AgentName::Single(s) => s, - _ => "<unknown>", + let bosses = log.boss_agents(); + let boss_name = if bosses.len() == 1 { + unwrap! { AgentName::Single(s) = bosses[0].name() => { s } } + } else { + "<unknown>" }.into(); let mut players = log |