diff options
| author | Nathan Perry <avaglir@gmail.com> | 2019-03-10 03:14:57 -0400 |
|---|---|---|
| committer | Nathan Perry <avaglir@gmail.com> | 2019-03-10 03:14:57 -0400 |
| commit | c9aa58ad38b9c32d4801e856288e3e7ca46c55de (patch) | |
| tree | 23b8da59c4cde2d0c6a4c8966da6e19415a73094 | |
| parent | 517cfcd44037fb6b556dddc2762f4755127cf3f4 (diff) | |
include non-installed games in updategaem output
| -rw-r--r-- | src/game.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/game.rs b/src/game.rs index 1099af5..9d66243 100644 --- a/src/game.rs +++ b/src/game.rs @@ -469,9 +469,9 @@ fn updategaem(_ctx: &mut Context, msg: &Message, mut args: Args) -> Result<()> { }, }; - let unknown_appids = (0..user_column.len()) + let missing_appids = (0..user_column.len()) .filter_map(|x| user_column[x].parse::<GameStatus>().ok().map(|s| (x, s))) - .filter(|(_, s)| *s == GameStatus::Unknown) + .filter(|(_, s)| *s == GameStatus::Unknown || *s == GameStatus::NotInstalled) .filter_map(|(x, _)| appid_column .get(x) .and_then(|s| s.parse::<u64>().ok().map(|appid| (appid, x)))); @@ -509,7 +509,7 @@ fn updategaem(_ctx: &mut Context, msg: &Message, mut args: Args) -> Result<()> { .map(|ge| ge.app_id) .collect::<FnvHashSet<_>>(); - let found_games = unknown_appids + let found_games = missing_appids .filter_map(|(ai, x)| if games_owned.contains(&ai) { Some(&spreadsheet[0][x + 1]) } else { |
