aboutsummaryrefslogtreecommitdiff
path: root/planetwars-server/src/routes/demo.rs
diff options
context:
space:
mode:
Diffstat (limited to 'planetwars-server/src/routes/demo.rs')
-rw-r--r--planetwars-server/src/routes/demo.rs10
1 files changed, 8 insertions, 2 deletions
diff --git a/planetwars-server/src/routes/demo.rs b/planetwars-server/src/routes/demo.rs
index 1a6ae9a..f9929f7 100644
--- a/planetwars-server/src/routes/demo.rs
+++ b/planetwars-server/src/routes/demo.rs
@@ -47,8 +47,14 @@ pub async fn submit_bot(
.expect("could not save bot code");
let mut run_match = RunMatch::from_players(vec![
- MatchPlayer::from_code_bundle_version(&player_bot_version),
- MatchPlayer::from_bot_version(&opponent_bot, &opponent_bot_version),
+ MatchPlayer::BotVersion {
+ bot: None,
+ version: player_bot_version.clone(),
+ },
+ MatchPlayer::BotVersion {
+ bot: Some(opponent_bot.clone()),
+ version: opponent_bot_version.clone(),
+ },
]);
let match_data = run_match
.store_in_database(&conn)